mirror of
https://github.com/ApfelTeeSaft/reactos.git
synced 2026-08-31 12:23:31 +00:00
Fixed the return value and last error in ConnectNamedPipe if a overlapped structure is given.
svn path=/trunk/; revision=14306
This commit is contained in:
@@ -330,20 +330,15 @@ ConnectNamedPipe(HANDLE hNamedPipe,
|
||||
0,
|
||||
NULL,
|
||||
0);
|
||||
if ((lpOverlapped != NULL) && (Status == STATUS_PENDING))
|
||||
return TRUE;
|
||||
|
||||
if ((lpOverlapped == NULL) && (Status == STATUS_PENDING))
|
||||
{
|
||||
Status = NtWaitForSingleObject(hNamedPipe,
|
||||
FALSE,
|
||||
NULL);
|
||||
if (!NT_SUCCESS(Status))
|
||||
if (NT_SUCCESS(Status))
|
||||
{
|
||||
SetLastErrorByStatus(Status);
|
||||
return FALSE;
|
||||
Status = Iosb.Status;
|
||||
}
|
||||
Status = Iosb.Status;
|
||||
}
|
||||
|
||||
if ((!NT_SUCCESS(Status) && Status != STATUS_PIPE_CONNECTED) ||
|
||||
|
||||
Reference in New Issue
Block a user