[KERNEL32]: SleepEx forgot to de-activate the SxS frame.

svn path=/trunk/; revision=52811
This commit is contained in:
Alex Ionescu 2011-07-23 17:17:06 +00:00
parent 1476736018
commit 8a945ffbf3
2 changed files with 6 additions and 0 deletions

View file

@ -702,6 +702,9 @@ SleepEx(IN DWORD dwMilliseconds,
errCode = NtDelayExecution((BOOLEAN)bAlertable, TimePtr);
}
while ((bAlertable) && (errCode == STATUS_ALERTED));
/* Cleanup the activation context */
if (bAlertable) RtlDeactivateActivationContextUnsafeFast(&ActCtx);
/* Return the correct code */
return (errCode == STATUS_USER_APC) ? WAIT_IO_COMPLETION : 0;

View file

@ -2832,7 +2832,10 @@ RtlDeactivateActivationContextUnsafeFast(IN PRTL_CALLER_ALLOCATED_ACTIVATION_CON
frame = &Frame->Frame;
if (!frame)
{
DPRINT1("No top frame!\n");
RtlRaiseStatus( STATUS_SXS_INVALID_DEACTIVATION );
}
/* pop everything up to and including frame */
NtCurrentTeb()->ActivationContextStackPointer->ActiveFrame = frame->Previous;