mirror of
https://github.com/reactos/reactos.git
synced 2024-12-29 02:25:17 +00:00
- Always try to uninitialize the file cache in VfatCleanupFile.
- Try to purge the file cache if the last handle is closed and deleting of the file was requested. svn path=/trunk/; revision=13276
This commit is contained in:
parent
afec493812
commit
4240c717c7
1 changed files with 13 additions and 7 deletions
|
@ -46,16 +46,22 @@ VfatCleanupFile(PVFAT_IRP_CONTEXT IrpContext)
|
||||||
VfatUpdateEntry (pFcb);
|
VfatUpdateEntry (pFcb);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Uninitialize file cache if initialized for this file object. */
|
if (pFcb->Flags & FCB_DELETE_PENDING &&
|
||||||
if (FileObject->PrivateCacheMap)
|
pFcb->OpenHandleCount == 1)
|
||||||
{
|
{
|
||||||
|
#if 0
|
||||||
|
/* FIXME:
|
||||||
|
* CcPurgeCacheSection is unimplemented.
|
||||||
|
*/
|
||||||
|
CcPurgeCacheSection(FileObject->SectionObjectPointer, NULL, 0, FALSE);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
/* Uninitialize file cache if. */
|
||||||
#ifdef USE_ROS_CC_AND_FS
|
#ifdef USE_ROS_CC_AND_FS
|
||||||
CcRosReleaseFileCache (FileObject);
|
CcRosReleaseFileCache (FileObject);
|
||||||
#else
|
#else
|
||||||
CcUninitializeCacheMap (FileObject, NULL, NULL);
|
CcUninitializeCacheMap (FileObject, NULL, NULL);
|
||||||
#endif
|
#endif
|
||||||
}
|
|
||||||
|
|
||||||
pFcb->OpenHandleCount--;
|
pFcb->OpenHandleCount--;
|
||||||
IoRemoveShareAccess(FileObject, &pFcb->FCBShareAccess);
|
IoRemoveShareAccess(FileObject, &pFcb->FCBShareAccess);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue