diff options
Diffstat (limited to 'sys/lib/libkern/scanc.c')
-rw-r--r-- | sys/lib/libkern/scanc.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/sys/lib/libkern/scanc.c b/sys/lib/libkern/scanc.c index 82b7e37cd30..0ebd9344333 100644 --- a/sys/lib/libkern/scanc.c +++ b/sys/lib/libkern/scanc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: scanc.c,v 1.4 2003/06/02 23:28:08 millert Exp $ */ +/* $OpenBSD: scanc.c,v 1.5 2004/08/07 00:38:33 deraadt Exp $ */ /* $NetBSD: scanc.c,v 1.3 1996/03/14 18:52:16 christos Exp $ */ /* @@ -36,14 +36,11 @@ #include <lib/libkern/libkern.h> int -scanc(size, cp, table, mask) - u_int size; - register const u_char *cp, table[]; - register u_char mask; +scanc(u_int size, const u_char *cp, const u_char table[], int mask) { - register const u_char *end = &cp[size]; + const u_char *end = &cp[size]; - while (cp < end && (table[*cp] & mask) == 0) + while (cp < end && (table[*cp] & (u_char)mask) == 0) cp++; return (end - cp); } |