While I am here, add more missing (unsigned char) casts to ctype() macros

This commit is contained in:
Andrey A. Chernov 2010-05-06 16:54:46 +00:00
parent 7024db1d40
commit e86a8937dc
2 changed files with 2 additions and 2 deletions

View File

@ -163,7 +163,7 @@ cal(void)
continue; continue;
/* Trim spaces in front of the tab */ /* Trim spaces in front of the tab */
while (isspace(pp[-1])) while (isspace((unsigned char)pp[-1]))
pp--; pp--;
p = *pp; p = *pp;

View File

@ -872,7 +872,7 @@ isonlydigits(char *s, int nostar)
for (i = 0; s[i] != '\0'; i++) { for (i = 0; s[i] != '\0'; i++) {
if (nostar == 0 && s[i] == '*' && s[i + 1] == '\0') if (nostar == 0 && s[i] == '*' && s[i + 1] == '\0')
return 1; return 1;
if (!isdigit(s[i])) if (!isdigit((unsigned char)s[i]))
return (0); return (0);
} }
return (1); return (1);