mirror of
https://github.com/reactos/reactos.git
synced 2025-08-05 07:32:57 +00:00
[NTOS:IO]
- Avoid event leak in NtQueryInformationFile. CID 716584 svn path=/trunk/; revision=74013
This commit is contained in:
parent
29446ab9a9
commit
156cf60be5
1 changed files with 11 additions and 2 deletions
|
@ -2240,8 +2240,17 @@ NtQueryInformationFile(IN HANDLE FileHandle,
|
||||||
}
|
}
|
||||||
_SEH2_END;
|
_SEH2_END;
|
||||||
|
|
||||||
/* Unlock FO */
|
/* Free the event if we had one */
|
||||||
|
if (LocalEvent)
|
||||||
|
{
|
||||||
|
ExFreePoolWithTag(Event, TAG_IO);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* If FO was locked, unlock it */
|
||||||
|
if (FileObject->Flags & FO_SYNCHRONOUS_IO)
|
||||||
|
{
|
||||||
IopUnlockFileObject(FileObject);
|
IopUnlockFileObject(FileObject);
|
||||||
|
}
|
||||||
|
|
||||||
/* We're done with FastIO! */
|
/* We're done with FastIO! */
|
||||||
ObDereferenceObject(FileObject);
|
ObDereferenceObject(FileObject);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue