More silencing of warnings

This commit is contained in:
twinaphex 2020-07-23 06:39:21 +02:00
parent 98516280ad
commit fa6d5333f7
2 changed files with 5 additions and 5 deletions

View file

@ -255,7 +255,7 @@ int filestream_scanf(RFILE *stream, const char* format, ...)
*subfmtiter++ = *format++;
}
while (isdigit(*format))
while (isdigit((unsigned char)*format))
*subfmtiter++ = *format++; /* width */
/* length */
@ -311,9 +311,9 @@ int filestream_scanf(RFILE *stream, const char* format, ...)
ret++;
bufiter += sublen;
}
else if (isspace(*format))
else if (isspace((unsigned char)*format))
{
while (isspace(*bufiter))
while (isspace((unsigned char)*bufiter))
bufiter++;
format++;
}

View file

@ -355,7 +355,7 @@ unsigned string_to_unsigned(const char *str)
for (ptr = str; *ptr != '\0'; ptr++)
{
if (!isdigit(*ptr))
if (!isdigit((unsigned char)*ptr))
return 0;
}
@ -388,7 +388,7 @@ unsigned string_hex_to_unsigned(const char *str)
/* Check for valid characters */
for (ptr = hex_str; *ptr != '\0'; ptr++)
{
if (!isxdigit(*ptr))
if (!isxdigit((unsigned char)*ptr))
return 0;
}