use Curl_inet_pton(), not inet_pton().
authorDaniel Stenberg <daniel@haxx.se>
Thu, 17 Mar 2005 07:40:15 +0000 (07:40 +0000)
committerDaniel Stenberg <daniel@haxx.se>
Thu, 17 Mar 2005 07:40:15 +0000 (07:40 +0000)
lib/hostip4.c
lib/hostip6.c

index 97c4236..a0d6d0c 100644 (file)
@@ -203,7 +203,7 @@ Curl_addrinfo *Curl_getaddrinfo(struct connectdata *conn,
 
   *waitp = 0; /* don't wait, we act synchronously */
 
-  if(1 == inet_pton(AF_INET, hostname, &in))
+  if(1 == Curl_inet_pton(AF_INET, hostname, &in))
     /* This is a dotted IP address 123.123.123.123-style */
     return Curl_ip2addr(in, hostname, port);
 
index 4da0507..ce58e64 100644 (file)
@@ -242,8 +242,8 @@ Curl_addrinfo *Curl_getaddrinfo(struct connectdata *conn,
     }
   }
 
-  if((1 == inet_pton(AF_INET, hostname, addrbuf)) ||
-     (1 == inet_pton(AF_INET6, hostname, addrbuf))) {
+  if((1 == Curl_inet_pton(AF_INET, hostname, addrbuf)) ||
+     (1 == Curl_inet_pton(AF_INET6, hostname, addrbuf))) {
     /* the given address is numerical only, prevent a reverse lookup */
     ai_flags = AI_NUMERICHOST;
   }