mirror of
https://github.com/open-simh/simh.git
synced 2026-05-03 22:58:53 +00:00
Fixed last change which only still worked if the OS returned the IPv6 socket first and now failed completely if not.
This commit is contained in:
@@ -721,7 +721,7 @@ if (preferred->ai_family == AF_INET6) {
|
|||||||
sta = setsockopt (newsock, IPPROTO_IPV6, IPV6_V6ONLY, (char *)&off, sizeof(off));
|
sta = setsockopt (newsock, IPPROTO_IPV6, IPV6_V6ONLY, (char *)&off, sizeof(off));
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
sta = bind (newsock, result->ai_addr, result->ai_addrlen);
|
sta = bind (newsock, preferred->ai_addr, preferred->ai_addrlen);
|
||||||
p_freeaddrinfo(result);
|
p_freeaddrinfo(result);
|
||||||
if (sta == SOCKET_ERROR) /* bind error? */
|
if (sta == SOCKET_ERROR) /* bind error? */
|
||||||
return sim_err_sock (newsock, "bind", 1);
|
return sim_err_sock (newsock, "bind", 1);
|
||||||
|
|||||||
Reference in New Issue
Block a user