Skip to content

Commit 9624ccc

Browse files
committed
addBuildOpt: use strncat instead of strlcat
Linux does not have strlcat.
1 parent 8c01bc3 commit 9624ccc

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/library/blas/generic/common.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -548,9 +548,10 @@ void addBuildOpt(
548548
if (l > 0 && !isspace(opts[l-1]) && l+1 < len) {
549549
opts[l] = ' ';
550550
opts[l+1] = '\0';
551+
l++;
551552
}
552553

553-
strlcat(opts, option, len);
554+
strncat(opts, option, len - l - 1);
554555
}
555556

556557

0 commit comments

Comments
 (0)