diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2013-11-26 13:21:19 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2013-11-26 13:21:19 +0000 |
commit | 42f68a7a6d855d973bf3c59d10e6519e0240d4f2 (patch) | |
tree | 64c16d6722fec7697ed1e37a4adecbda0314e831 /usr.bin/jot/jot.c | |
parent | 9c87bfa9d5ea46fd4fe5c8edb947aec28e748573 (diff) |
unsigned char casts for ctype
ok krw
Diffstat (limited to 'usr.bin/jot/jot.c')
-rw-r--r-- | usr.bin/jot/jot.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/usr.bin/jot/jot.c b/usr.bin/jot/jot.c index b773e6001d3..23ba16b3095 100644 --- a/usr.bin/jot/jot.c +++ b/usr.bin/jot/jot.c @@ -1,4 +1,4 @@ -/* $OpenBSD: jot.c,v 1.22 2013/11/15 15:47:53 millert Exp $ */ +/* $OpenBSD: jot.c,v 1.23 2013/11/26 13:21:18 deraadt Exp $ */ /* $NetBSD: jot.c,v 1.3 1994/12/02 20:29:43 pk Exp $ */ /*- @@ -337,7 +337,7 @@ getprec(char *s) if (*p == '\0') return (0); for (q = ++p; *p != '\0'; p++) - if (!isdigit(*p)) + if (!isdigit((unsigned char)*p)) break; return (p - q); } @@ -378,8 +378,8 @@ getformat(void) */ p2 = p++; dot = hash = space = sign = numbers = 0; - while (!isalpha(*p)) { - if (isdigit(*p)) { + while (!isalpha((unsigned char)*p)) { + if (isdigit((unsigned char)*p)) { numbers++; p++; } else if ((*p == '#' && !(numbers|dot|sign|space| |