[FASTFAT]
authorThomas Faber <thomas.faber@reactos.org>
Mon, 20 Oct 2014 09:31:50 +0000 (09:31 +0000)
committerThomas Faber <thomas.faber@reactos.org>
Mon, 20 Oct 2014 09:31:50 +0000 (09:31 +0000)
- Move FCB list removal to vfatDelFCBFromTable, since vfatAddFCBToTable does the insert. Fixes list corruption in vfatUpdateFCB.

svn path=/trunk/; revision=64843

reactos/drivers/filesystems/fastfat/fcb.c

index 9f104a2..251821b 100644 (file)
@@ -199,6 +199,8 @@ vfatDelFCBFromTable(
         }
         entry->next = pFCB->Hash.next;
     }
         }
         entry->next = pFCB->Hash.next;
     }
+
+    RemoveEntryList(&pFCB->FcbListEntry);
 }
 
 static
 }
 
 static
@@ -302,7 +304,6 @@ vfatReleaseFCB(
         {
             ASSERT(pFCB->OpenHandleCount == 0);
             tmpFcb = pFCB->parentFcb;
         {
             ASSERT(pFCB->OpenHandleCount == 0);
             tmpFcb = pFCB->parentFcb;
-            RemoveEntryList (&pFCB->FcbListEntry);
             vfatDelFCBFromTable(pVCB, pFCB);
             vfatDestroyFCB(pFCB);
         }
             vfatDelFCBFromTable(pVCB, pFCB);
             vfatDestroyFCB(pFCB);
         }