From 815c76f4aeb141fa9654bc3abc16998c8188268f Mon Sep 17 00:00:00 2001 From: Nils Durner Date: Tue, 1 Sep 2009 21:15:09 +0000 Subject: [PATCH] Windows returns EWOULDBLOCK instead of EINPROGRESS --- src/util/network.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/util/network.c b/src/util/network.c index ce3f7b40b..7e4743a10 100644 --- a/src/util/network.c +++ b/src/util/network.c @@ -182,7 +182,11 @@ GNUNET_NETWORK_socket_connect (const struct GNUNET_NETWORK_Handle *desc, ret = connect (desc->fd, address, address_len); #ifdef MINGW if (SOCKET_ERROR == ret) - SetErrnoFromWinsockError (WSAGetLastError ()); + { + SetErrnoFromWinsockError (WSAGetLastError ()); + if (errno == EWOULDBLOCK) + errno = EINPROGRESS; + } #endif return ret == 0 ? GNUNET_OK : GNUNET_SYSERR; } -- 2.25.1