diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2003-09-10 07:10:43 +0000 |
---|---|---|
committer | Paul Eggert <eggert@cs.ucla.edu> | 2003-09-10 07:10:43 +0000 |
commit | 6545de6ca88cf3ef985d38cbb10d022c63b24dbe (patch) | |
tree | 30da648dc52b6d9e34af5122ff04523f453f12f9 /lib/strchrnul.c | |
parent | d01e199f674be88351d5956a13fe6dc406efacb5 (diff) | |
download | gnulib-6545de6ca88cf3ef985d38cbb10d022c63b24dbe.tar.gz |
Remove K&R cruft.
Diffstat (limited to 'lib/strchrnul.c')
-rw-r--r-- | lib/strchrnul.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/lib/strchrnul.c b/lib/strchrnul.c index 694e24a0ab..db42e28734 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)) + unsigned char c = c_in; + while (*s && (*s != c)) s++; - return (char*) s; + return (char *) s; } |