diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index 8e9b3ac81..5b224913a 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,3 +1,8 @@ +Sat Mar 17 18:10:00 2001 Corinna Vinschen + + * net.cc (cygwin_socket): Set protocol to 0 when address family is + AF_UNIX to avoid WSAEPROTONOSUPPORT error. + Sat Mar 17 09:51:32 2001 Mathew Brozowski * net.cc (cygwin_socket): Pass protocol parameter to socket call. diff --git a/winsup/cygwin/net.cc b/winsup/cygwin/net.cc index ee95f7ac5..f0cf9a758 100644 --- a/winsup/cygwin/net.cc +++ b/winsup/cygwin/net.cc @@ -352,7 +352,7 @@ cygwin_socket (int af, int type, int protocol) { debug_printf ("socket (%d, %d, %d)", af, type, protocol); - soc = socket (AF_INET, type, protocol); + soc = socket (AF_INET, type, af == AF_UNIX ? 0 : protocol); if (soc == INVALID_SOCKET) {