fr::TcpSocket bug fix
Recv's return value was being checked to see if it was greater or equal to 0, if everything was okay. 0 indicates connection closed, and so the socket should have disconnected instead of returning Success.
This commit is contained in:
parent
e748fde121
commit
ec95d0ac36
@ -55,7 +55,7 @@ namespace fr
|
||||
//Read RECV_CHUNK_SIZE bytes into the recv buffer
|
||||
int64_t status = ::recv(socket_descriptor, (char*)data, buffer_size, 0);
|
||||
|
||||
if(status >= 0)
|
||||
if(status > 0)
|
||||
{
|
||||
received += status;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user