mirror of
https://github.com/reactos/reactos.git
synced 2025-02-23 17:05:46 +00:00
[CSQ]
Add even more sanity checks svn path=/trunk/; revision=69489
This commit is contained in:
parent
4c064550ec
commit
0a193d609a
1 changed files with 10 additions and 2 deletions
|
@ -337,6 +337,8 @@ IoCsqRemoveIrp(
|
|||
if(!Irp)
|
||||
break;
|
||||
|
||||
ASSERT(Context->Csq == Csq);
|
||||
|
||||
/* Unset the cancel routine and see if it has already been canceled */
|
||||
if(!IoSetCancelRoutine(Irp, NULL))
|
||||
{
|
||||
|
@ -348,6 +350,8 @@ IoCsqRemoveIrp(
|
|||
break;
|
||||
}
|
||||
|
||||
ASSERT(Context == Irp->Tail.Overlay.DriverContext[3]);
|
||||
|
||||
/* This IRP is valid and is ours. Dequeue it, fix it up, and return */
|
||||
Csq->CsqRemoveIrp(Csq, Irp);
|
||||
|
||||
|
@ -358,7 +362,7 @@ IoCsqRemoveIrp(
|
|||
Context->Irp = NULL;
|
||||
|
||||
ASSERT(Context->Csq == Csq);
|
||||
}
|
||||
}
|
||||
}
|
||||
while(0);
|
||||
|
||||
|
@ -412,9 +416,13 @@ IoCsqRemoveNextIrp(
|
|||
/* Unset the context stuff and return */
|
||||
Context = (PIO_CSQ_IRP_CONTEXT)InterlockedExchangePointer(&Irp->Tail.Overlay.DriverContext[3], NULL);
|
||||
|
||||
if(Context && Context->Type == IO_TYPE_CSQ_IRP_CONTEXT)
|
||||
if (Context && Context->Type == IO_TYPE_CSQ_IRP_CONTEXT)
|
||||
{
|
||||
Context->Irp = NULL;
|
||||
|
||||
ASSERT(Context->Csq == Csq);
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue