mirror of
https://github.com/curl/curl.git
synced 2026-05-15 11:06:21 +03:00
Fixed display of the interface bind address in the trace output when it's
an IPv6 address.
This commit is contained in:
parent
57d13c770a
commit
bc0ebfcdeb
1 changed files with 1 additions and 3 deletions
|
|
@ -340,9 +340,7 @@ static CURLcode bindlocal(struct connectdata *conn,
|
|||
if(h) {
|
||||
if(in == CURL_INADDR_NONE)
|
||||
/* convert the resolved address, sizeof myhost >= INET_ADDRSTRLEN */
|
||||
Curl_inet_ntop(h->addr->ai_addr->sa_family,
|
||||
&((struct sockaddr_in*)h->addr->ai_addr)->sin_addr,
|
||||
myhost, sizeof myhost);
|
||||
Curl_printable_address(h->addr, myhost, sizeof myhost);
|
||||
else
|
||||
/* we know data->set.device is shorter than the myhost array */
|
||||
strcpy(myhost, dev);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue