qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH for 2.6] wxx: Fix broken TCP networking (regression)
@ 2016-04-14 17:46 Stefan Weil
  2016-04-14 17:53 ` Michael Fritscher
                   ` (3 more replies)
  0 siblings, 4 replies; 11+ messages in thread
From: Stefan Weil @ 2016-04-14 17:46 UTC (permalink / raw)
  To: QEMU Developer
  Cc: Daniel P. Berrange, Paolo Bonzini, Jan Kiszka, Samuel Thibault,
	Peter Maydell, Michael Fritscher, Stefan Weil

It is broken since commit c619644067f98098dcdbc951e2dda79e97560afa.

Reported-by: Michael Fritscher <michael@fritscher.net>
Signed-off-by: Stefan Weil <sw@weilnetz.de>
---

Networking with QEMU for Windows is currently not usable,
see bug report https://bugs.launchpad.net/qemu/+bug/1569988.

With this patch, it seems to work again at least partially.
Michael Fritscher reported that it is still slow, so
more fixes might be needed.

Would it be better to add conditional compilation to
slirp/tcp_input.c again (then the changes would only
be for Windows, so no new risk for QEMU 2.6)?

Peter, I'd appreciate to get Windows networking fixed
for 2.6, so feel free to modify and apply this patch as
needed if time is too short for reviews and my pull request.

Regards,
Stefan

 slirp/slirp.h     | 5 -----
 slirp/tcp_input.c | 1 +
 2 files changed, 1 insertion(+), 5 deletions(-)

diff --git a/slirp/slirp.h b/slirp/slirp.h
index c99ebb9..203deec 100644
--- a/slirp/slirp.h
+++ b/slirp/slirp.h
@@ -347,9 +347,4 @@ struct tcpcb *tcp_drop(struct tcpcb *tp, int err);
 #define max(x,y) ((x) > (y) ? (x) : (y))
 #endif
 
-#ifdef _WIN32
-#undef errno
-#define errno (WSAGetLastError())
-#endif
-
 #endif
diff --git a/slirp/tcp_input.c b/slirp/tcp_input.c
index 5433e7f..e2b5d4e 100644
--- a/slirp/tcp_input.c
+++ b/slirp/tcp_input.c
@@ -659,6 +659,7 @@ findso:
 	  }
 
 	  if ((tcp_fconnect(so, so->so_ffamily) == -1) &&
+              (errno != EAGAIN) &&
               (errno != EINPROGRESS) && (errno != EWOULDBLOCK)
           ) {
 	    uint8_t code;
-- 
2.1.4

^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2016-04-15 17:52 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-04-14 17:46 [Qemu-devel] [PATCH for 2.6] wxx: Fix broken TCP networking (regression) Stefan Weil
2016-04-14 17:53 ` Michael Fritscher
2016-04-14 18:08 ` Samuel Thibault
2016-04-14 18:54   ` Michael Fritscher
2016-04-15  9:35     ` Michael Fritscher
2016-04-14 19:12 ` Peter Maydell
2016-04-15  9:15   ` Daniel P. Berrange
2016-04-15 16:56     ` Stefan Weil
2016-04-15 16:59       ` Peter Maydell
2016-04-15 17:52         ` Stefan Weil
2016-04-15  9:11 ` Daniel P. Berrange

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).