Signed-off-by: Zebediah Figura zfigura@codeweavers.com --- dlls/ntoskrnl.exe/ntoskrnl.c | 1 + dlls/ntoskrnl.exe/tests/driver.c | 10 ++++------ 2 files changed, 5 insertions(+), 6 deletions(-)
diff --git a/dlls/ntoskrnl.exe/ntoskrnl.c b/dlls/ntoskrnl.exe/ntoskrnl.c index fb3f9a23152..b2ffb7cfbb2 100644 --- a/dlls/ntoskrnl.exe/ntoskrnl.c +++ b/dlls/ntoskrnl.exe/ntoskrnl.c @@ -1989,6 +1989,7 @@ VOID WINAPI IoCompleteRequest( IRP *irp, UCHAR priority_boost ) device = IoGetCurrentIrpStackLocation(irp)->DeviceObject; else device = NULL; + irp->PendingReturned = !!(irpsp->Control & SL_PENDING_RETURNED); if (call_flag) { TRACE( "calling %p( %p, %p, %p )\n", routine, device, irp, irpsp->Context ); diff --git a/dlls/ntoskrnl.exe/tests/driver.c b/dlls/ntoskrnl.exe/tests/driver.c index 65c7860e786..8a4856ca3f0 100644 --- a/dlls/ntoskrnl.exe/tests/driver.c +++ b/dlls/ntoskrnl.exe/tests/driver.c @@ -1746,9 +1746,8 @@ static NTSTATUS WINAPI completion_cb(DEVICE_OBJECT *device, IRP *irp, void *cont
if (device == upper_device) { - todo_wine_if (completion_lower_pending) - ok(irp->PendingReturned == completion_lower_pending, "Got PendingReturned %u, expected %u.\n", - irp->PendingReturned, completion_lower_pending); + ok(irp->PendingReturned == completion_lower_pending, "Got PendingReturned %u, expected %u.\n", + irp->PendingReturned, completion_lower_pending);
ok(irp->CurrentLocation == 2, "Got current location %u.\n", irp->CurrentLocation); ok(stack->Control == (SL_INVOKE_ON_CANCEL | SL_INVOKE_ON_ERROR | SL_INVOKE_ON_SUCCESS), @@ -1763,9 +1762,8 @@ static NTSTATUS WINAPI completion_cb(DEVICE_OBJECT *device, IRP *irp, void *cont } else { - todo_wine_if (completion_upper_pending) - ok(irp->PendingReturned == completion_upper_pending, "Got PendingReturned %u, expected %u.\n", - irp->PendingReturned, completion_upper_pending); + ok(irp->PendingReturned == completion_upper_pending, "Got PendingReturned %u, expected %u.\n", + irp->PendingReturned, completion_upper_pending);
ok(irp->CurrentLocation == 3, "Got current location %u.\n", irp->CurrentLocation); ok(!stack->Control, "Got control flags %#x.\n", stack->Control);