lib/string.c: allow searching for NUL with strnchr