From 8529188f6aed5d083babc6b89d22f2a94d0ebd6d Mon Sep 17 00:00:00 2001 From: dmiller Date: Sun, 13 Dec 2015 21:39:48 +0000 Subject: [PATCH] Handle ENETRESET/WSAENETRESET on WIN32 When this case was added in r29097, the #ifndef was mistaken for #ifdef. The error, which was only discovered on Windows, was therefore not handled only on Windows systems. This commit makes the check unconditional. http://seclists.org/nmap-dev/2015/q4/217 --- service_scan.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/service_scan.cc b/service_scan.cc index bfdf2fbb3..4c1807081 100644 --- a/service_scan.cc +++ b/service_scan.cc @@ -2564,13 +2564,13 @@ static void servicescan_read_handler(nsock_pool nsp, nsock_event nse, void *myda */ #ifndef WIN32 case EPIPE: +#endif case ENETRESET: //This error (same as WSAENETRESET according to nbase_winunix) is Microsoft only error, where the connected host crashes and then resets during the communication //More information can be found at http://www.sockets.com/err_lst1.htm#WSAENETRESET. //I assume that we shouldn't bother doing anything beyond catching it, and then going on to the next probe. -#endif #ifdef EPROTO case EPROTO: // EPROTO is suspected to be caused by an active IDS/IPS that forges ICMP