mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-15 11:03:00 +01:00
Fix issue in ReceiveData
This commit is contained in:
committed by
Ted John
parent
291667d5bf
commit
3116ec3e76
@@ -369,7 +369,12 @@ public:
|
||||
}
|
||||
|
||||
int readBytes = recv(_socket, (char *)buffer, size, 0);
|
||||
if (readBytes == SOCKET_ERROR || readBytes <= 0)
|
||||
if (readBytes == 0)
|
||||
{
|
||||
*sizeReceived = 0;
|
||||
return NETWORK_READPACKET_DISCONNECTED;
|
||||
}
|
||||
else if (readBytes == SOCKET_ERROR)
|
||||
{
|
||||
*sizeReceived = 0;
|
||||
if (LAST_SOCKET_ERROR() != EWOULDBLOCK && LAST_SOCKET_ERROR() != EAGAIN)
|
||||
|
||||
Reference in New Issue
Block a user