Author: tfaber Date: Thu Sep 15 13:25:20 2016 New Revision: 72682
URL: http://svn.reactos.org/svn/reactos?rev=72682&view=rev Log: [NTOS:IO] - Avoid IRP allocation failure in IopDeleteFile and IopCloseFile. Based on a patch by Volodymyr Shcherbyna. CORE-11959
Modified: trunk/reactos/ntoskrnl/io/iomgr/file.c
Modified: trunk/reactos/ntoskrnl/io/iomgr/file.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/io/iomgr/file.c?re... ============================================================================== --- trunk/reactos/ntoskrnl/io/iomgr/file.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/io/iomgr/file.c [iso-8859-1] Thu Sep 15 13:25:20 2016 @@ -1283,8 +1283,7 @@ KeInitializeEvent(&Event, SynchronizationEvent, FALSE);
/* Allocate an IRP */ - Irp = IoAllocateIrp(DeviceObject->StackSize, FALSE); - if (!Irp) return; + Irp = IopAllocateIrpMustSucceed(DeviceObject->StackSize);
/* Set it up */ Irp->UserEvent = &Event; @@ -1977,8 +1976,7 @@ KeInitializeEvent(&Event, SynchronizationEvent, FALSE);
/* Allocate an IRP */ - Irp = IoAllocateIrp(DeviceObject->StackSize, FALSE); - if (!Irp) return; + Irp = IopAllocateIrpMustSucceed(DeviceObject->StackSize);
/* Set it up */ Irp->UserEvent = &Event;