mirror of
https://github.com/python/cpython.git
synced 2025-11-25 04:34:37 +00:00
Remove all other uses of the C tolower()/toupper() which could break with a Turkish locale.
This commit is contained in:
parent
1665d2c75f
commit
ed8ba14441
3 changed files with 6 additions and 6 deletions
|
|
@ -1102,8 +1102,8 @@ to_int(int c)
|
|||
if (isdigit(c))
|
||||
return c - '0';
|
||||
else {
|
||||
if (isupper(c))
|
||||
c = tolower(c);
|
||||
if (Py_ISUPPER(c))
|
||||
c = Py_TOLOWER(c);
|
||||
if (c >= 'a' && c <= 'f')
|
||||
return c - 'a' + 10;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue