Off by one error in checking max file name length.
This commit is contained in:
parent
be9ab92241
commit
3adb054e5a
@ -86,7 +86,7 @@ main(int argc, char **argv)
|
||||
while (argc > 0) {
|
||||
memcpy(path, p, pathlen);
|
||||
|
||||
if (strlen(*argv) > FILENAME_MAX ||
|
||||
if (strlen(*argv) >= FILENAME_MAX ||
|
||||
print_matches(path, *argv) == -1)
|
||||
status = EXIT_FAILURE;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user