mirror of
https://github.com/solemnwarning/ipxwrapper
synced 2024-12-30 16:45:37 +01:00
Updated shutdown to work with SPX sockets.
This commit is contained in:
parent
94d3a6cbbd
commit
ae2837258f
@ -1107,18 +1107,25 @@ int PASCAL shutdown(SOCKET fd, int cmd)
|
|||||||
|
|
||||||
if(sock)
|
if(sock)
|
||||||
{
|
{
|
||||||
if(cmd == SD_RECEIVE || cmd == SD_BOTH)
|
if(sock->flags & IPX_IS_SPX)
|
||||||
{
|
{
|
||||||
sock->flags &= ~IPX_RECV;
|
unlock_sockets();
|
||||||
|
return r_shutdown(fd, cmd);
|
||||||
}
|
}
|
||||||
|
else{
|
||||||
if(cmd == SD_SEND || cmd == SD_BOTH)
|
if(cmd == SD_RECEIVE || cmd == SD_BOTH)
|
||||||
{
|
{
|
||||||
sock->flags &= ~IPX_SEND;
|
sock->flags &= ~IPX_RECV;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(cmd == SD_SEND || cmd == SD_BOTH)
|
||||||
|
{
|
||||||
|
sock->flags &= ~IPX_SEND;
|
||||||
|
}
|
||||||
|
|
||||||
|
unlock_sockets();
|
||||||
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
unlock_sockets();
|
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
return r_shutdown(fd, cmd);
|
return r_shutdown(fd, cmd);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user