use inet_pton() correctly!

This commit is contained in:
Daniel Stenberg 2004-08-20 09:11:52 +00:00
parent 06d39bd303
commit 93b61bf0d3
1 changed files with 1 additions and 1 deletions

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 */
ai_flags = AI_NUMERICHOST;
}