[RTL] Partially sync wait.c with Wine Staging 1.7.55. By Samuel Serapión. CORE-10536 CORE-10577

svn path=/trunk/; revision=70200
This commit is contained in:
Amine Khaldi 2015-11-29 16:35:51 +00:00
parent f995d57b93
commit 4f7f9c423e
2 changed files with 9 additions and 5 deletions

View file

@ -44,7 +44,7 @@ Wait_thread_proc(LPVOID Arg)
{ {
PRTLP_WAIT Wait = (PRTLP_WAIT) Arg; PRTLP_WAIT Wait = (PRTLP_WAIT) Arg;
NTSTATUS Status; NTSTATUS Status;
BOOLEAN alertable = (Wait->Flags & WT_EXECUTEINIOTHREAD) ? TRUE : FALSE; BOOLEAN alertable = (Wait->Flags & WT_EXECUTEINIOTHREAD) != 0;
HANDLE handles[2] = { Wait->Object, Wait->CancelEvent }; HANDLE handles[2] = { Wait->Object, Wait->CancelEvent };
LARGE_INTEGER timeout; LARGE_INTEGER timeout;
HANDLE completion_event; HANDLE completion_event;
@ -84,7 +84,7 @@ Wait_thread_proc(LPVOID Arg)
if (Wait->Flags & WT_EXECUTEONLYONCE) if (Wait->Flags & WT_EXECUTEONLYONCE)
break; break;
} }
else else if (Status != STATUS_USER_APC)
break; break;
} }
@ -157,7 +157,7 @@ RtlRegisterWait(PHANDLE NewWaitObject,
Status = NtCreateEvent( &Wait->CancelEvent, Status = NtCreateEvent( &Wait->CancelEvent,
EVENT_ALL_ACCESS, EVENT_ALL_ACCESS,
NULL, NULL,
TRUE, NotificationEvent,
FALSE ); FALSE );
if (Status != STATUS_SUCCESS) if (Status != STATUS_SUCCESS)
@ -166,9 +166,12 @@ RtlRegisterWait(PHANDLE NewWaitObject,
return Status; return Status;
} }
Flags = Flags & (WT_EXECUTEINIOTHREAD | WT_EXECUTEINPERSISTENTTHREAD |
WT_EXECUTELONGFUNCTION | WT_TRANSFER_IMPERSONATION);
Status = RtlQueueWorkItem( Wait_thread_proc, Status = RtlQueueWorkItem( Wait_thread_proc,
Wait, Wait,
Flags & ~WT_EXECUTEONLYONCE ); Flags );
if (Status != STATUS_SUCCESS) if (Status != STATUS_SUCCESS)
{ {
@ -214,7 +217,7 @@ RtlDeregisterWaitEx(HANDLE WaitHandle,
Status = NtCreateEvent( &CompletionEvent, Status = NtCreateEvent( &CompletionEvent,
EVENT_ALL_ACCESS, EVENT_ALL_ACCESS,
NULL, NULL,
TRUE, NotificationEvent,
FALSE ); FALSE );
if (Status != STATUS_SUCCESS) if (Status != STATUS_SUCCESS)

View file

@ -254,6 +254,7 @@ reactos/lib/3rdparty/strmbase # Synced to WineStaging-1.7.55
reactos/lib/rtl/actctx.c # Partly synced with WineStaging-1.7.55 reactos/lib/rtl/actctx.c # Partly synced with WineStaging-1.7.55
reactos/lib/rtl/timerqueue.c # Partly synced with WineStaging-1.7.55 reactos/lib/rtl/timerqueue.c # Partly synced with WineStaging-1.7.55
reactos/lib/rtl/wait.c # Partly synced with WineStaging-1.7.55
advapi32 - advapi32 -
reactos/dll/win32/advapi32/wine/cred.c # Synced to WineStaging-1.7.55 reactos/dll/win32/advapi32/wine/cred.c # Synced to WineStaging-1.7.55