[USBPORT] Remove unnecessary null check in USBPORT_HandleSubmitURB (CID 1419367).
authorThomas Faber <thomas.faber@reactos.org>
Wed, 11 Oct 2017 15:15:46 +0000 (17:15 +0200)
committerThomas Faber <ThFabba@users.noreply.github.com>
Fri, 13 Oct 2017 21:36:29 +0000 (23:36 +0200)
drivers/usb/usbport/urb.c

index a9d7d07..0792068 100644 (file)
@@ -1056,10 +1056,7 @@ USBPORT_HandleSubmitURB(IN PDEVICE_OBJECT PdoDevice,
         ExFreePoolWithTag(Transfer, USB_PORT_TAG);
     }
 
-    if (DeviceHandle)
-    {
-        InterlockedDecrement(&DeviceHandle->DeviceHandleLock);
-    }
+    InterlockedDecrement(&DeviceHandle->DeviceHandleLock);
 
     Irp->IoStatus.Status = Status;
     IoCompleteRequest(Irp, IO_NO_INCREMENT);