mirror of
https://github.com/irungentoo/toxcore.git
synced 2024-03-22 13:30:51 +08:00
Merge pull request #616 from naxuroqa/master
fix for missing EAGAIN definition on windows
This commit is contained in:
commit
f5179afe4c
|
@ -212,9 +212,12 @@ int sendpacket(Networking_Core *net, IP_Port ip_port, uint8_t *data, uint32_t le
|
|||
|
||||
if (res == length)
|
||||
net->send_fail_eagain = 0;
|
||||
#ifdef WIN32
|
||||
else if ((res < 0) && (errno == WSAEWOULDBLOCK))
|
||||
#else
|
||||
else if ((res < 0) && (errno == EAGAIN))
|
||||
#endif
|
||||
net->send_fail_eagain = current_time();
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user