From 5ab8e37be664c842cec58a51ffc7c8adfe543707 Mon Sep 17 00:00:00 2001 From: david Date: Thu, 6 Sep 2012 20:11:08 +0000 Subject: [PATCH] Recognize WSAEADDRINUSE in handle_connect_result. This happens on Windows when two sockets bind to the same local port and connect to the same remote port on a remote host. I tried this on Linux; Linux prevents the second bind from succeeding. http://seclists.org/nmap-dev/2012/q2/513 --- nsock/src/nsock_core.c | 1 + 1 file changed, 1 insertion(+) diff --git a/nsock/src/nsock_core.c b/nsock/src/nsock_core.c index e4c8cda1b..39bb0bb87 100644 --- a/nsock/src/nsock_core.c +++ b/nsock/src/nsock_core.c @@ -349,6 +349,7 @@ void handle_connect_result(mspool *ms, msevent *nse, enum nse_status status) { case EHOSTDOWN: case ECONNRESET: #ifdef WIN32 + case WSAEADDRINUSE: case WSAEADDRNOTAVAIL: #endif #ifndef WIN32