mirror of
https://github.com/reactos/reactos.git
synced 2025-08-05 22:52:54 +00:00
[NTOSKRNL]
Implement RtlpCloseHandleCallback, closing the handle table, and use it as callback for ExSweepHandleTable in RtlpDestroyAtomHandleTable. Without a callback ExSweepHandleTable simply crashes, so obviously we never clean up any atom tables, possibly because the window station is never closed. svn path=/trunk/; revision=61039
This commit is contained in:
parent
954e21ccc0
commit
6f0131873e
1 changed files with 13 additions and 2 deletions
|
@ -535,14 +535,25 @@ RtlpCreateAtomHandleTable(PRTL_ATOM_TABLE AtomTable)
|
||||||
return (AtomTable->ExHandleTable != NULL);
|
return (AtomTable->ExHandleTable != NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
BOOLEAN
|
||||||
|
NTAPI
|
||||||
|
RtlpCloseHandleCallback(
|
||||||
|
IN PHANDLE_TABLE_ENTRY HandleTableEntry,
|
||||||
|
IN HANDLE Handle,
|
||||||
|
IN PVOID HandleTable)
|
||||||
|
{
|
||||||
|
/* Destroy and unlock the handle entry */
|
||||||
|
return ExDestroyHandle(HandleTable, Handle, HandleTableEntry);
|
||||||
|
}
|
||||||
|
|
||||||
VOID
|
VOID
|
||||||
RtlpDestroyAtomHandleTable(PRTL_ATOM_TABLE AtomTable)
|
RtlpDestroyAtomHandleTable(PRTL_ATOM_TABLE AtomTable)
|
||||||
{
|
{
|
||||||
if (AtomTable->ExHandleTable)
|
if (AtomTable->ExHandleTable)
|
||||||
{
|
{
|
||||||
ExSweepHandleTable(AtomTable->ExHandleTable,
|
ExSweepHandleTable(AtomTable->ExHandleTable,
|
||||||
NULL,
|
RtlpCloseHandleCallback,
|
||||||
NULL);
|
AtomTable->ExHandleTable);
|
||||||
ExDestroyHandleTable(AtomTable->ExHandleTable, NULL);
|
ExDestroyHandleTable(AtomTable->ExHandleTable, NULL);
|
||||||
AtomTable->ExHandleTable = NULL;
|
AtomTable->ExHandleTable = NULL;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue