diff options
author | dsl <dsl@NetBSD.org> | 2004-11-05 21:30:31 +0000 |
---|---|---|
committer | dsl <dsl@NetBSD.org> | 2004-11-05 21:30:31 +0000 |
commit | 9649fe0209de88926626165951e2db3043b73ee6 (patch) | |
tree | f7d328358e6de9a877c8d0fc24f5ae49ad21f031 /monop/getinp.c | |
parent | ef4d58572f66f86a3db4aa555d139fee63cca10c (diff) | |
download | bsdgames-darwin-9649fe0209de88926626165951e2db3043b73ee6.tar.gz bsdgames-darwin-9649fe0209de88926626165951e2db3043b73ee6.tar.zst bsdgames-darwin-9649fe0209de88926626165951e2db3043b73ee6.zip |
Add (unsigned char) cast to ctype functions
Diffstat (limited to 'monop/getinp.c')
-rw-r--r-- | monop/getinp.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/monop/getinp.c b/monop/getinp.c index 3fb739b4..fee84c5e 100644 --- a/monop/getinp.c +++ b/monop/getinp.c @@ -1,4 +1,4 @@ -/* $NetBSD: getinp.c,v 1.12 2004/01/27 20:30:30 jsm Exp $ */ +/* $NetBSD: getinp.c,v 1.13 2004/11/05 21:30:32 dsl Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)getinp.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: getinp.c,v 1.12 2004/01/27 20:30:30 jsm Exp $"); +__RCSID("$NetBSD: getinp.c,v 1.13 2004/11/05 21:30:32 dsl Exp $"); #endif #endif /* not lint */ @@ -91,8 +91,7 @@ inter: } *sp = '\0'; for (sp = buf; *sp; sp++) - if (isupper(*sp)) - *sp = tolower(*sp); + *sp = tolower((unsigned char)*sp); for (i = n_match = 0; list[i]; i++) if (comp(list[i])) { n_match++; @@ -115,7 +114,7 @@ comp(s1) if (buf[0] != '\0') for (sp = buf, tsp = s1; *sp; ) { - c = isupper(*tsp) ? tolower(*tsp) : *tsp; + c = tolower((unsigned char)*tsp); tsp++; if (c != *sp++) return 0; |