s_serv: connect using both IPv4 and IPv6 if unspecified

This commit is contained in:
Simon Arlott 2017-08-22 21:55:03 +01:00
parent de2934965c
commit 4ce1cac4b9
No known key found for this signature in database
GPG key ID: B98AF2C7BD763505

View file

@ -1043,7 +1043,7 @@ serv_connect(struct server_conf *server_p, struct Client *by)
SET_SS_FAMILY(&sa_connect, AF_UNSPEC);
SET_SS_FAMILY(&sa_bind, AF_UNSPEC);
if(server_p->aftype != AF_UNSPEC
if(server_p->aftype == AF_UNSPEC
&& GET_SS_FAMILY(&server_p->connect4) == AF_INET
&& GET_SS_FAMILY(&server_p->connect6) == AF_INET6)
{