X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;f=lib%2Fstrchrnul.c;h=be85312c4611b55587e0b91eb12ebd1d03761a91;hb=1a58ab824a26d93fee2b6f131ff070d1b72116c9;hp=694e24a0ab3a2afd1ec316131a4dcb1750378cdd;hpb=2d0fc24aba5e2c71a55b991a6e0ba6a01110581f;p=gnulib.git diff --git a/lib/strchrnul.c b/lib/strchrnul.c index 694e24a0a..be85312c4 100644 --- a/lib/strchrnul.c +++ b/lib/strchrnul.c @@ -20,12 +20,11 @@ /* Find the first occurrence of C in S or the final NUL byte. */ char * -strchrnul (s, c_in) - const char *s; - int c_in; +strchrnul (const char *s, int c_in) { - while (*s && (*s != c_in)) + char c = c_in; + while (*s && (*s != c)) s++; - return (char*) s; + return (char *) s; }