diff options
author | 2015-10-24 17:51:59 +0000 | |
---|---|---|
committer | 2015-10-24 17:51:59 +0000 | |
commit | d02bbd4a6175d8e06e740d0cd1ff1ca0964fcfd2 (patch) | |
tree | 13d019798a3f5b1bb50dcb766ca9cde59684ed4f | |
parent | Cast isprint()'s argument to unsigned char. (diff) | |
download | wireguard-openbsd-d02bbd4a6175d8e06e740d0cd1ff1ca0964fcfd2.tar.xz wireguard-openbsd-d02bbd4a6175d8e06e740d0cd1ff1ca0964fcfd2.zip |
Cast ctype functions' arguments to unsigned char.
ok guenther@
-rw-r--r-- | games/mille/move.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/games/mille/move.c b/games/mille/move.c index de0e0dc3ffd..374e3c3b520 100644 --- a/games/mille/move.c +++ b/games/mille/move.c @@ -1,4 +1,4 @@ -/* $OpenBSD: move.c,v 1.13 2014/11/16 04:49:48 guenther Exp $ */ +/* $OpenBSD: move.c,v 1.14 2015/10/24 17:51:59 mmcc Exp $ */ /* $NetBSD: move.c,v 1.4 1995/03/24 05:01:57 cgd Exp $ */ /* @@ -345,9 +345,9 @@ getmove() refresh(); while ((c = readch()) == killchar() || c == erasechar()) continue; - if (islower(c)) - c = toupper(c); - if (isprint(c) && !isspace(c)) { + if (islower((unsigned char)c)) + c = toupper((unsigned char)c); + if (isprint((unsigned char)c) && !isspace((unsigned char)c)) { addch(c); refresh(); } |