[libbus/pnp] Disassociate a deleted FDO
authorShao Miller <Shao.Miller@yrdsb.edu.on.ca>
Mon, 3 Jan 2011 08:53:36 +0000 (03:53 -0500)
committerShao Miller <Shao.Miller@yrdsb.edu.on.ca>
Mon, 3 Jan 2011 08:53:36 +0000 (03:53 -0500)
src/winvblock/libbus/pnp.c

index 141ad45..3a761d9 100644 (file)
@@ -124,6 +124,8 @@ static NTSTATUS STDCALL WvlBusPnpRemoveDev(IN WVL_SP_BUS_T bus, IN PIRP irp) {
       IoDetachDevice(lower);
     /* Delete. */
     IoDeleteDevice(bus->Fdo);
+    /* Disassociate. */
+    bus->Fdo = NULL;
     /* Stop the thread. */
     bus->Stop = TRUE;
     return status;