diff options
| author | he <he@NetBSD.org> | 2004-11-13 14:32:14 +0000 |
|---|---|---|
| committer | he <he@NetBSD.org> | 2004-11-13 14:32:14 +0000 |
| commit | f5ee27d6520384cc27f43c3a66eef59115fd7339 (patch) | |
| tree | 324be30437c675920ca5401b180fff9fba493607 /usr.sbin/grfconfig | |
| parent | 7139fbfc165852d84aad93b461d8d49fbb4bc0e6 (diff) | |
Add casts to unsigned char for the arguments to ctype.h functions.
Diffstat (limited to 'usr.sbin/grfconfig')
| -rw-r--r-- | usr.sbin/grfconfig/grfconfig.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/usr.sbin/grfconfig/grfconfig.c b/usr.sbin/grfconfig/grfconfig.c index 9cc12823566..37b5479ec3b 100644 --- a/usr.sbin/grfconfig/grfconfig.c +++ b/usr.sbin/grfconfig/grfconfig.c @@ -1,4 +1,4 @@ -/* $NetBSD: grfconfig.c,v 1.10 2001/01/22 21:11:23 is Exp $ */ +/* $NetBSD: grfconfig.c,v 1.11 2004/11/13 14:32:14 he Exp $ */ /*- * Copyright (c) 1997 The NetBSD Foundation, Inc. @@ -43,7 +43,7 @@ __COPYRIGHT("@(#) Copyright (c) 1997 The NetBSD Foundation, Inc.\n\ #endif /* not lint */ #ifndef lint -__RCSID("$NetBSD: grfconfig.c,v 1.10 2001/01/22 21:11:23 is Exp $"); +__RCSID("$NetBSD: grfconfig.c,v 1.11 2004/11/13 14:32:14 he Exp $"); #endif /* not lint */ #include <sys/file.h> @@ -142,11 +142,11 @@ main(ac, av) * check for end-of-section, comments, strip off trailing * spaces and newline character. */ - for (p = buf; isspace(*p); ++p) + for (p = buf; isspace((unsigned char)*p); ++p) continue; if (*p == '\0' || *p == '#') continue; - for (p = strchr(buf, '\0'); isspace(*--p);) + for (p = strchr(buf, '\0'); isspace((unsigned char)*--p);) continue; *++p = '\0'; @@ -157,8 +157,8 @@ main(ac, av) *tbuf2 = '\0'; break; } - if (isupper(*tbuf2)) { - *tbuf2 = tolower(*tbuf2); + if (isupper((unsigned char)*tbuf2)) { + *tbuf2 = tolower((unsigned char)*tbuf2); } obuf++; tbuf2++; |
