mirror of
https://github.com/reactos/reactos.git
synced 2024-09-28 21:44:31 +00:00
[NTOS:IO] Fix IRP stack location check in IoForwardIrpSynchronously
We are doing IoCallDriver here, so the valid stack location should be CurrentLocation <= Irp->StackCount (just a check for a completly incorrect value) && CurrentLocation > 1 (ensure that we have a place for another call) CORE-17189 Co-authored-by: Thomas Faber <thomas.faber@reactos.org>
This commit is contained in:
parent
8fa3c147b6
commit
f562f9c5c6
|
@ -1629,7 +1629,7 @@ IoForwardIrpSynchronously(IN PDEVICE_OBJECT DeviceObject,
|
|||
NTSTATUS Status;
|
||||
|
||||
/* Check if next stack location is available */
|
||||
if (Irp->CurrentLocation < Irp->StackCount)
|
||||
if (Irp->CurrentLocation > Irp->StackCount || Irp->CurrentLocation <= 1)
|
||||
{
|
||||
/* No more stack location */
|
||||
return FALSE;
|
||||
|
|
Loading…
Reference in a new issue