[FASTFAT] Don't delay any other close once shutdown has started
[reactos.git] / drivers / filesystems / fastfat / close.c
index 0c313e6..d8f85a8 100644 (file)
@@ -183,7 +183,8 @@ VfatCloseFile(
     }
 
     /* If we have to close immediately, or if delaying failed, close */
-    if (!BooleanFlagOn(pFcb->Flags, FCB_DELAYED_CLOSE) || !NT_SUCCESS(VfatPostCloseFile(DeviceExt, FileObject)))
+    if (VfatGlobalData->ShutdownStarted || !BooleanFlagOn(pFcb->Flags, FCB_DELAYED_CLOSE) ||
+        !NT_SUCCESS(VfatPostCloseFile(DeviceExt, FileObject)))
     {
         VfatCommonCloseFile(DeviceExt, pFcb);
     }