[FASTFAT]
authorPierre Schweitzer <pierre@reactos.org>
Sun, 26 Oct 2014 20:29:00 +0000 (20:29 +0000)
committerPierre Schweitzer <pierre@reactos.org>
Sun, 26 Oct 2014 20:29:00 +0000 (20:29 +0000)
Make sure the appropriate resource is exclusively acquired when playing with FCB references

svn path=/trunk/; revision=65033

reactos/drivers/filesystems/fastfat/fcb.c

index 0b5f24a..c698ba7 100644 (file)
@@ -292,6 +292,8 @@ vfatGrabFCB(
     PDEVICE_EXTENSION pVCB,
     PVFATFCB pFCB)
 {
+    ASSERT(ExIsResourceAcquiredExclusive(&pVCB->DirResource));
+
     ++pFCB->RefCount;
 }
 
@@ -305,6 +307,8 @@ vfatReleaseFCB(
     DPRINT("releasing FCB at %p: %wZ, refCount:%d\n",
            pFCB, &pFCB->PathNameU, pFCB->RefCount);
 
+    ASSERT(ExIsResourceAcquiredExclusive(&pVCB->DirResource));
+
     while (pFCB)
     {
         pFCB->RefCount--;