diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2004-08-07 00:38:34 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2004-08-07 00:38:34 +0000 |
commit | 6199f15e3e0651e8399ad97e919a96d69d128ee2 (patch) | |
tree | cde8dbb44682b9bafafa3ec82a63352162d5cf59 /sys/lib/libkern/scanc.c | |
parent | f8b1d50fcd985a3171e1d491c63c553aff62c2a7 (diff) |
ansi and some missing protos
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); } |