1
0
mirror of https://github.com/moparisthebest/curl synced 2024-12-22 16:18:48 -05:00

use inet_pton() correctly!

This commit is contained in:
Daniel Stenberg 2004-08-20 09:11:52 +00:00
parent 06d39bd303
commit 93b61bf0d3

View File

@ -247,7 +247,7 @@ Curl_addrinfo *Curl_getaddrinfo(struct connectdata *conn,
} }
} }
if(1 == inet_pton(pf, addrbuf, sizeof(addrbuf))) { if(1 == inet_pton(pf, hostname, addrbuf)) {
/* the given address is numerical only, prevent a reverse lookup */ /* the given address is numerical only, prevent a reverse lookup */
ai_flags = AI_NUMERICHOST; ai_flags = AI_NUMERICHOST;
} }