inet_pton.c: use locale-independent tolower
authorJim Meyering <meyering@redhat.com>
Wed, 6 Aug 2008 09:49:11 +0000 (11:49 +0200)
committerJim Meyering <meyering@redhat.com>
Wed, 6 Aug 2008 11:22:07 +0000 (13:22 +0200)
* lib/inet_pton.c: Include <c-ctype.h> rather than <ctype.h>.
(inet_pton6): Use c_tolower rather than tolower.
* modules/inet_pton (Depends-on): Add c-ctype.

ChangeLog
lib/inet_pton.c
modules/inet_pton

index 9273b33..0ab1322 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2008-08-06  Jim Meyering  <meyering@redhat.com>
+
+       inet_pton.c: use locale-independent tolower
+       * lib/inet_pton.c: Include <c-ctype.h> rather than <ctype.h>.
+       (inet_pton6): Use c_tolower rather than tolower.
+       * modules/inet_pton (Depends-on): Add c-ctype.
+
 2008-08-06  Paolo Bonzini  <bonzini@gnu.org>
 
        * lib/poll.c (poll): Avoid division when timeout is 0, cache
index 261caf1..62ef145 100644 (file)
@@ -37,7 +37,7 @@
 /* Specification.  */
 #include <arpa/inet.h>
 
-#include <ctype.h>
+#include <c-ctype.h>
 #include <string.h>
 #include <errno.h>
 
@@ -179,7 +179,7 @@ inet_pton6 (const char *restrict src, unsigned char *restrict dst)
   curtok = src;
   saw_xdigit = 0;
   val = 0;
-  while ((ch = tolower (*src++)) != '\0')
+  while ((ch = c_tolower (*src++)) != '\0')
     {
       const char *pch;
 
index deafb60..173710a 100644 (file)
@@ -6,6 +6,7 @@ lib/inet_pton.c
 m4/inet_pton.m4
 
 Depends-on:
+c-ctype
 socklen
 sys_socket
 arpa_inet