X-Git-Url: https://git.distorted.org.uk/~mdw/sgt/puzzles/blobdiff_plain/9ec8a3176a8fe57877548f2226a91d702c63b849..4d6d127734e9debf3eb909b3a5817110fcc67bf5:/singles.c diff --git a/singles.c b/singles.c index d8016ff..c20d0cf 100644 --- a/singles.c +++ b/singles.c @@ -324,7 +324,7 @@ static char n2c(int num) { } static int c2n(char c) { - if (isdigit(c)) + if (isdigit((unsigned char)c)) return (int)(c - '0'); else if (c >= 'a' && c <= 'z') return (int)(c - 'a' + 10);