Updated the implementation of socketpair for Windows with AF_UNIX to call either the _dgram od _stream version of socketpair()

This commit is contained in:
Fabrizio Bertocci 2021-03-13 14:29:30 -05:00
parent 7ae7010aa7
commit 507b85de51

View file

@ -60,7 +60,9 @@ int socketpair(int family, int type, int protocol, int sv[2]) {
* works with type==SOCK_STREAM and not with
* SOCK_DGRAM (as well as SOCK_SEQPACKET)
*/
return sys_socketpair_nt_stream(AF_INET, SOCK_STREAM, 0, sv);
/* Force to build an AF_INET socketpair */
family = AF_INET;
/*
errno = EAFNOSUPPORT;
return -1;