1
0
mirror of https://github.com/moparisthebest/curl synced 2024-08-13 17:03:50 -04:00

only use sockaddr_in6 on ipv6-enabled hosts

This commit is contained in:
Daniel Stenberg 2004-06-24 09:13:50 +00:00
parent 9729df1756
commit 8d0a823124

View File

@ -332,7 +332,11 @@ static CURLcode bindlocal(struct connectdata *conn,
if( bind(sockfd, addr->ai_addr, addr->ai_addrlen) >= 0) {
/* we succeeded to bind */
#ifdef ENABLE_IPV6
struct sockaddr_in6 add;
#else
struct sockaddr_in add;
#endif
bindworked = TRUE;