mirror of
https://git.planet-casio.com/Vhex-Kernel-Core/fxlibc.git
synced 2024-12-26 19:43:37 +01:00
fix: uppercase letters not recognized by strtol() etc.
This commit is contained in:
parent
83d0ab858e
commit
dd735428b0
1 changed files with 1 additions and 1 deletions
|
@ -49,7 +49,7 @@ int __strto_int(struct __scanf_input *input, int base, long *outl,
|
|||
int v = -1;
|
||||
int c = __scanf_peek(input);
|
||||
if(isdigit(c)) v = c - '0';
|
||||
if(islower(c)) v = c - 'a' + 10;
|
||||
if(isalpha(c)) v = tolower(c) - 'a' + 10;
|
||||
if(v == -1 || v >= base) break;
|
||||
|
||||
/* The value is valid as long as there is at least one digit */
|
||||
|
|
Loading…
Reference in a new issue