diff options
author | 2015-10-24 17:34:16 +0000 | |
---|---|---|
committer | 2015-10-24 17:34:16 +0000 | |
commit | 3c57379406116cdf99483cfd28f44a5b70a602cb (patch) | |
tree | 564f97fbc8b8292f4aca168f7fe4faf2adac4eb2 | |
parent | Cast isdigit()'s argument to unsigned char. (diff) | |
download | wireguard-openbsd-3c57379406116cdf99483cfd28f44a5b70a602cb.tar.xz wireguard-openbsd-3c57379406116cdf99483cfd28f44a5b70a602cb.zip |
Cast isblank()'s argument to unsigned char.
ok guenther@
-rw-r--r-- | games/primes/primes.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/games/primes/primes.c b/games/primes/primes.c index f5e9478ae6d..860d9a23049 100644 --- a/games/primes/primes.c +++ b/games/primes/primes.c @@ -1,4 +1,4 @@ -/* $OpenBSD: primes.c,v 1.16 2015/09/07 00:49:20 tedu Exp $ */ +/* $OpenBSD: primes.c,v 1.17 2015/10/24 17:34:16 mmcc Exp $ */ /* $NetBSD: primes.c,v 1.5 1995/04/24 12:24:47 cgd Exp $ */ /* @@ -184,7 +184,7 @@ read_num_buf(void) exit(0); } buf[strcspn(buf, "\n")] = '\0'; - for (p = buf; isblank(*p); ++p) + for (p = buf; isblank((unsigned char)*p); ++p) ; if (*p == '\0') continue; @@ -194,7 +194,7 @@ read_num_buf(void) val = strtoul(buf, &p, 10); if (errno) err(1, "%s", buf); - for (; isblank(*p); ++p) + for (; isblank((unsigned char)*p); ++p) ; if (*p != '\0') errx(1, "%s: illegal numeric format.", buf); |