mirror of
https://github.com/postgres/postgres.git
synced 2025-06-26 12:21:12 +03:00
inet_net_pton.c: use pg_ascii_tolower() rather than tolower().
Avoid dependence on setlocale(). No behavior change. Discussion: https://postgr.es/m/9875f7f9-50f1-4b5d-86fc-ee8b03e8c162@eisentraut.org Reviewed-by: Peter Eisentraut <peter@eisentraut.org>
This commit is contained in:
@ -115,8 +115,7 @@ inet_cidr_pton_ipv4(const char *src, u_char *dst, size_t size)
|
||||
src++; /* skip x or X. */
|
||||
while ((ch = *src++) != '\0' && isxdigit((unsigned char) ch))
|
||||
{
|
||||
if (isupper((unsigned char) ch))
|
||||
ch = tolower((unsigned char) ch);
|
||||
ch = pg_ascii_tolower((unsigned char) ch);
|
||||
n = strchr(xdigits, ch) - xdigits;
|
||||
assert(n >= 0 && n <= 15);
|
||||
if (dirty == 0)
|
||||
|
Reference in New Issue
Block a user