Skip to content
Snippets Groups Projects
Commit 8b80ac28 authored by Daniel Stenberg's avatar Daniel Stenberg
Browse files

use Curl_inet_pton(), not inet_pton().

parent 23323774
No related branches found
No related tags found
No related merge requests found
......@@ -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);
......
......@@ -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;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment