kernel32: Wait on pipe handle in TransactNamedPipe if needed.

Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Jacek Caban 2018-10-30 16:08:27 +01:00 committed by Alexandre Julliard
parent b114bd07b1
commit 4fc5aff509

View file

@ -1746,6 +1746,11 @@ BOOL WINAPI TransactNamedPipe(
status = NtFsControlFile(handle, event, NULL, cvalue, iosb, FSCTL_PIPE_TRANSCEIVE,
write_buf, write_size, read_buf, read_size);
if (status == STATUS_PENDING && !overlapped)
{
WaitForSingleObject(handle, INFINITE);
status = iosb->u.Status;
}
if (bytes_read) *bytes_read = overlapped && status ? 0 : iosb->Information;