summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--toxcore/network.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/toxcore/network.c b/toxcore/network.c
index 51f064e7..38adc179 100644
--- a/toxcore/network.c
+++ b/toxcore/network.c
@@ -212,9 +212,12 @@ int sendpacket(Networking_Core *net, IP_Port ip_port, uint8_t *data, uint32_t le
212 212
213 if (res == length) 213 if (res == length)
214 net->send_fail_eagain = 0; 214 net->send_fail_eagain = 0;
215#ifdef WIN32
216 else if ((res < 0) && (errno == WSAEWOULDBLOCK))
217#else
215 else if ((res < 0) && (errno == EAGAIN)) 218 else if ((res < 0) && (errno == EAGAIN))
216 net->send_fail_eagain = current_time(); 219#endif
217 220 net->send_fail_eagain = current_time();
218 return res; 221 return res;
219} 222}
220 223