Fix minor windows pedantic warnings.

This commit is contained in:
Jason Felds
2016-03-27 22:03:15 -04:00
parent 534909d30a
commit bec18a0d36
31 changed files with 173 additions and 67 deletions
+9 -1
View File
@@ -40,17 +40,25 @@ static const char *itoa(unsigned n)
static intptr_t xtoi( const char *hex )
{
intptr_t ret = 0;
while( 1 )
for(;;)
{
int val = -1;
if( *hex >= '0' && *hex <= '9' )
{
val = *hex - '0';
}
else if( *hex >= 'A' && *hex <= 'F' )
{
val = *hex - 'A' + 10;
}
else if( *hex >= 'a' && *hex <= 'f' )
{
val = *hex - 'a' + 10;
}
else
{
break;
}
hex++;
ret *= 16;