1
0
mirror of https://github.com/nmap/nmap.git synced 2026-01-06 06:29:03 +00:00

Don't quit on ERROR_IO_INCOMPLETE. Closes #1372

This commit is contained in:
dmiller
2018-10-26 20:50:58 +00:00
parent 1c2829cbd0
commit 86d1f7e66e
2 changed files with 11 additions and 4 deletions

View File

@@ -1,5 +1,8 @@
#Nmap Changelog ($Id$); -*-text-*-
o [Ncat][GH#1372] Fixed an issue with Ncat -e on Windows that caused early
termination of connections. [Alberto Garcia Illera]
o [GH#1361] Deprecate and disable the -PR (ARP ping) host discovery option. ARP
ping is already used whenever possible, and the -PR option would not force it
to be used in any other case. [Daniel Miller]

View File

@@ -547,10 +547,14 @@ static DWORD WINAPI subprocess_thread_func(void *data)
} else {
/* Probably read result wasn't ready, but we got here because
* there was data on the socket. */
if (GetLastError() != ERROR_IO_PENDING)
{
/* Error or end of file. */
goto loop_end;
switch (GetLastError()) {
case ERROR_IO_PENDING:
case ERROR_IO_INCOMPLETE:
break;
default:
/* Error or end of file. */
goto loop_end;
break;
}
}
/* Break here, don't go on. Need to finish all socket writes before