[FASTFAT] Improve code style in addition to 8294118174b28a10daec3f763d8b5ab64104d1fa.
[reactos.git] / drivers / filesystems / fastfat / cleanup.c
index 85b4ea2..0a12fd7 100644 (file)
@@ -41,6 +41,7 @@ VfatCleanupFile(
     if (IsVolume)
     {
         pFcb->OpenHandleCount--;
+        DeviceExt->OpenHandleCount--;
 
         if (pFcb->OpenHandleCount != 0)
         {
@@ -123,16 +124,11 @@ VfatCleanupFile(
         {
             VfatDelEntry(DeviceExt, pFcb, NULL);
 
-            FsRtlNotifyFullReportChange(DeviceExt->NotifySync,
-                                        &(DeviceExt->NotifyList),
-                                        (PSTRING)&pFcb->PathNameU,
-                                        pFcb->PathNameU.Length - pFcb->LongNameU.Length,
-                                        NULL,
-                                        NULL,
-                                        vfatFCBIsDirectory(pFcb) ?
-                                        FILE_NOTIFY_CHANGE_DIR_NAME : FILE_NOTIFY_CHANGE_FILE_NAME,
-                                        FILE_ACTION_REMOVED,
-                                        NULL);
+            vfatReportChange(DeviceExt,
+                             pFcb,
+                             (vfatFCBIsDirectory(pFcb) ?
+                              FILE_NOTIFY_CHANGE_DIR_NAME : FILE_NOTIFY_CHANGE_FILE_NAME),
+                             FILE_ACTION_REMOVED);
         }
 
         if (pFcb->OpenHandleCount != 0)