From: David Dykstra Date: Fri, 14 Dec 2001 18:00:54 +0000 (+0000) Subject: open_socket_in was attempting to try all the protocols returned from X-Git-Tag: v2.5.1~16 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=cb1bcc7ebbb84a056a63fd09e47c456509c52411;p=thirdparty%2Frsync.git open_socket_in was attempting to try all the protocols returned from getaddrinfo(), but only if a corresponding call to socket() returned one of three *NOSUPPORT errno codes. A Redhat 6.2 system was observed returning EINVAL instead so it never went on to try IPv4. This update adds EINVAL to the list. Question: why not always continue through the list regardless of what errno is? --- diff --git a/socket.c b/socket.c index 58d3dde3..0ad8a169 100644 --- a/socket.c +++ b/socket.c @@ -298,6 +298,7 @@ static int open_socket_in(int type, int port, const char *bind_address, case EPROTONOSUPPORT: case EAFNOSUPPORT: case EPFNOSUPPORT: + case EINVAL: /* See if there's another address that will work... */ continue; }