aboutsummaryrefslogtreecommitdiff
path: root/slirp
diff options
context:
space:
mode:
authorStefan Weil <sw@weilnetz.de>2015-07-30 23:08:12 +0200
committerStefan Weil <sw@weilnetz.de>2015-09-24 20:52:28 +0200
commita246a01631f90230374c2b8ffce608232e2aa654 (patch)
treed96410e6ad26f8b3443778d9969528c2021976f3 /slirp
parent805d8a67647768173c27761cd86e6f99a9d3b7cd (diff)
downloadqemu-arm-a246a01631f90230374c2b8ffce608232e2aa654.tar.gz
slirp: Fix non blocking connect for w32
Signed-off-by: Stefan Weil <sw@weilnetz.de>
Diffstat (limited to 'slirp')
-rw-r--r--slirp/tcp_input.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/slirp/tcp_input.c b/slirp/tcp_input.c
index f946db8dc0..00a77b4a5f 100644
--- a/slirp/tcp_input.c
+++ b/slirp/tcp_input.c
@@ -584,7 +584,13 @@ findso:
goto cont_input;
}
- if((tcp_fconnect(so) == -1) && (errno != EINPROGRESS) && (errno != EWOULDBLOCK)) {
+ if ((tcp_fconnect(so) == -1) &&
+#if defined(_WIN32)
+ socket_error() != WSAEWOULDBLOCK
+#else
+ (errno != EINPROGRESS) && (errno != EWOULDBLOCK)
+#endif
+ ) {
u_char code=ICMP_UNREACH_NET;
DEBUG_MISC((dfd, " tcp fconnect errno = %d-%s\n",
errno,strerror(errno)));