mirror of
https://github.com/reactos/reactos.git
synced 2025-08-05 12:13:01 +00:00
[NTOS:EX] Don't dereference ExpCritSecOutOfMemoryEvent when it was never referenced.
This commit is contained in:
parent
c32993c672
commit
f555c102b7
1 changed files with 10 additions and 4 deletions
|
@ -457,8 +457,11 @@ NtWaitForKeyedEvent(
|
||||||
/* Do the wait */
|
/* Do the wait */
|
||||||
Status = ExpWaitForKeyedEvent(KeyedEvent, Key, Alertable, Timeout);
|
Status = ExpWaitForKeyedEvent(KeyedEvent, Key, Alertable, Timeout);
|
||||||
|
|
||||||
/* Dereference the keyed event */
|
if (Handle != NULL)
|
||||||
ObDereferenceObject(KeyedEvent);
|
{
|
||||||
|
/* Dereference the keyed event */
|
||||||
|
ObDereferenceObject(KeyedEvent);
|
||||||
|
}
|
||||||
|
|
||||||
/* Return the status */
|
/* Return the status */
|
||||||
return Status;
|
return Status;
|
||||||
|
@ -523,8 +526,11 @@ NtReleaseKeyedEvent(
|
||||||
/* Do the wait */
|
/* Do the wait */
|
||||||
Status = ExpReleaseKeyedEvent(KeyedEvent, Key, Alertable, Timeout);
|
Status = ExpReleaseKeyedEvent(KeyedEvent, Key, Alertable, Timeout);
|
||||||
|
|
||||||
/* Dereference the keyed event */
|
if (Handle != NULL)
|
||||||
ObDereferenceObject(KeyedEvent);
|
{
|
||||||
|
/* Dereference the keyed event */
|
||||||
|
ObDereferenceObject(KeyedEvent);
|
||||||
|
}
|
||||||
|
|
||||||
/* Return the status */
|
/* Return the status */
|
||||||
return Status;
|
return Status;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue