mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
patch(1): replace strnlen() with a simpler strlen().
Small style fix with here. Pointed out by: kib
This commit is contained in:
parent
4f548c1916
commit
fa81223743
1 changed files with 2 additions and 2 deletions
|
|
@ -749,10 +749,10 @@ rej_line(int ch, LINENUM i)
|
|||
size_t len;
|
||||
const char *line = pfetch(i);
|
||||
|
||||
len = strnlen(line, USHRT_MAX);
|
||||
len = strlen(line);
|
||||
|
||||
fprintf(rejfp, "%c%s", ch, line);
|
||||
if (len == 0 || line[len-1] != '\n') {
|
||||
if (len == 0 || line[len - 1] != '\n') {
|
||||
if (len >= USHRT_MAX)
|
||||
fprintf(rejfp, "\n\\ Line too long\n");
|
||||
else
|
||||
|
|
|
|||
Loading…
Reference in a new issue