[NTOS]: Fix kernel memory corruption when dequeuing a PnP event

svn path=/trunk/; revision=48422
This commit is contained in:
Cameron Gutman 2010-08-02 21:22:34 +00:00
parent 917fbfd1ea
commit db0f412b3e

View file

@ -98,7 +98,7 @@ IopRemovePlugPlayEvent(VOID)
/* Remove a pnp event entry from the tail of the queue */ /* Remove a pnp event entry from the tail of the queue */
if (!IsListEmpty(&IopPnpEventQueueHead)) if (!IsListEmpty(&IopPnpEventQueueHead))
{ {
ExFreePool(RemoveTailList(&IopPnpEventQueueHead)); ExFreePool(CONTAINING_RECORD(RemoveTailList(&IopPnpEventQueueHead), PNP_EVENT_ENTRY, ListEntry)));
} }
/* Signal the next pnp event in the queue */ /* Signal the next pnp event in the queue */