Author: tfaber
Date: Sun Nov 6 15:26:39 2016
New Revision: 73153
URL:
http://svn.reactos.org/svn/reactos?rev=73153&view=rev
Log:
[KMTESTS]
- Complete IRPs with STATUS_INVALID_DEVICE_REQUEST by default.
CORE-12295 #resolve
Modified:
trunk/rostests/kmtests/kmtest_drv/kmtest_standalone.c
Modified: trunk/rostests/kmtests/kmtest_drv/kmtest_standalone.c
URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/kmtests/kmtest_drv/kmtest…
==============================================================================
--- trunk/rostests/kmtests/kmtest_drv/kmtest_standalone.c [iso-8859-1] (original)
+++ trunk/rostests/kmtests/kmtest_drv/kmtest_standalone.c [iso-8859-1] Sun Nov 6 15:26:39
2016
@@ -306,7 +306,7 @@
IN PDEVICE_OBJECT DeviceObject,
IN PIRP Irp)
{
- NTSTATUS Status = STATUS_SUCCESS;
+ NTSTATUS Status = STATUS_INVALID_DEVICE_REQUEST;
PIO_STACK_LOCATION IoStackLocation;
int i;
@@ -328,6 +328,12 @@
if (IoStackLocation->MajorFunction == IRP_MJ_DEVICE_CONTROL ||
IoStackLocation->MajorFunction == IRP_MJ_INTERNAL_DEVICE_CONTROL)
return DeviceControlHandler(DeviceObject, Irp, IoStackLocation);
+
+ /* Return success for create, close, and cleanup */
+ if (IoStackLocation->MajorFunction == IRP_MJ_CREATE ||
+ IoStackLocation->MajorFunction == IRP_MJ_CLOSE ||
+ IoStackLocation->MajorFunction == IRP_MJ_CLEANUP)
+ Status = STATUS_SUCCESS;
/* default handler */
Irp->IoStatus.Status = Status;