ntdll: Don't write more IOCP entries than requested.

Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=45948
Signed-off-by: Zebediah Figura <z.figura12@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Zebediah Figura 2018-11-17 20:06:17 -06:00 committed by Alexandre Julliard
parent fbde01335f
commit e09248d363
1 changed files with 2 additions and 2 deletions

View File

@ -1351,7 +1351,7 @@ NTSTATUS WINAPI NtRemoveIoCompletionEx( HANDLE port, FILE_IO_COMPLETION_INFORMAT
for (;;) for (;;)
{ {
for (;;) while (i < count)
{ {
SERVER_START_REQ( remove_completion ) SERVER_START_REQ( remove_completion )
{ {
@ -1368,7 +1368,7 @@ NTSTATUS WINAPI NtRemoveIoCompletionEx( HANDLE port, FILE_IO_COMPLETION_INFORMAT
if (ret != STATUS_SUCCESS) break; if (ret != STATUS_SUCCESS) break;
if (i++ >= count) break; ++i;
} }
if (i || ret != STATUS_PENDING) if (i || ret != STATUS_PENDING)