about summary refs log tree commit diff
path: root/sysdeps/generic/strchrnul.c
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>1999-06-14 09:25:22 +0000
committerUlrich Drepper <drepper@redhat.com>1999-06-14 09:25:22 +0000
commit28e351249e754446ab86c9cdc5bdbe2747cff998 (patch)
treeb222260b53c9d5e477f5cec36319fb36ebabb3bb /sysdeps/generic/strchrnul.c
parent6d525e7a639fa681d82892628b3c6fa1acbf8c93 (diff)
downloadglibc-28e351249e754446ab86c9cdc5bdbe2747cff998.tar.gz
glibc-28e351249e754446ab86c9cdc5bdbe2747cff998.tar.xz
glibc-28e351249e754446ab86c9cdc5bdbe2747cff998.zip
Update.
	* sysdeps/generic/strchr.c: Include <memcopy.h> and use reg_char
	for character to search, to help the compiler.
	* sysdeps/generic/strchrnul.c: Likewise.
	* sysdeps/generic/memchr.c: Likewise.
	* sysdeps/generic/memccpy.c: Likewise.
	* sysdeps/generic/rawmemchr.c: Likewise.  Fix comment.

1999-06-13  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
Diffstat (limited to 'sysdeps/generic/strchrnul.c')
-rw-r--r--sysdeps/generic/strchrnul.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/sysdeps/generic/strchrnul.c b/sysdeps/generic/strchrnul.c
index 1d6ece5332..b88fecba6d 100644
--- a/sysdeps/generic/strchrnul.c
+++ b/sysdeps/generic/strchrnul.c
@@ -21,21 +21,23 @@
    Boston, MA 02111-1307, USA.  */
 
 #include <string.h>
+#include <memcopy.h>
 
 #undef __strchrnul
 #undef strchrnul
 
 /* Find the first occurrence of C in S or the final NUL byte.  */
 char *
-__strchrnul (s, c)
+__strchrnul (s, c_in)
      const char *s;
-     int c;
+     int c_in;
 {
   const unsigned char *char_ptr;
   const unsigned long int *longword_ptr;
   unsigned long int longword, magic_bits, charmask;
+  unsigned reg_char c;
 
-  c = (unsigned char) c;
+  c = (unsigned char) c_in;
 
   /* Handle the first few characters by reading one character at a time.
      Do this until CHAR_PTR is aligned on a longword boundary.  */