- VFAT fixes: Actually perform a mandatory call to CcPurgeCacheSection during file deletion (fixes real NT5 cache manager attempts to write section of a deleted file).

- VFAT fixes: When querying FileStandardInformation, NT's fastfat driver sets NumberOfLinks to 1, ours sets it to 0 somewhy. Change to 1 for compatibility.
- A couple of debug prints improvements in VFAT.
- Comment out UNIMPLEMENTED in CcPurgeCacheSection to prevent debug messages flood.

svn path=/trunk/; revision=36830
This commit is contained in:
Aleksey Bragin
2008-10-19 13:23:00 +00:00
parent 0690324f95
commit fc64051142
3 changed files with 5 additions and 9 deletions
@@ -82,12 +82,7 @@ VfatCleanupFile(PVFAT_IRP_CONTEXT IrpContext)
ObDereferenceObject(tmpFileObject);
}
#if 0
/* FIXME:
* CcPurgeCacheSection is unimplemented.
*/
CcPurgeCacheSection(FileObject->SectionObjectPointer, NULL, 0, FALSE);
#endif
}
/* Uninitialize file cache if. */
if (FileObject->SectionObjectPointer->SharedCacheMap)
+4 -3
View File
@@ -91,7 +91,7 @@ VfatGetStandardInformation(PVFATFCB FCB,
StandardInfo->EndOfFile = FCB->RFCB.FileSize;
StandardInfo->Directory = FALSE;
}
StandardInfo->NumberOfLinks = 0;
StandardInfo->NumberOfLinks = 1;
StandardInfo->DeletePending = FCB->Flags & FCB_DELETE_PENDING ? TRUE : FALSE;
*BufferLength -= sizeof(FILE_STANDARD_INFORMATION);
@@ -271,7 +271,7 @@ VfatSetDispositionInformation(PFILE_OBJECT FileObject,
PDEVICE_EXTENSION DeviceExt = DeviceObject->DeviceExtension;
#endif
DPRINT ("FsdSetDispositionInformation()\n");
DPRINT ("FsdSetDispositionInformation(<%wZ>, Delete %d)\n", &FCB->PathNameU, DispositionInfo->DeleteFile);
ASSERT(DeviceExt != NULL);
ASSERT(DeviceExt->FatInfo.BytesPerCluster != 0);
@@ -551,7 +551,8 @@ VfatSetAllocationSizeInformation(PFILE_OBJECT FileObject,
ULONG NCluster;
BOOLEAN AllocSizeChanged = FALSE;
DPRINT("VfatSetAllocationSizeInformation()\n");
DPRINT("VfatSetAllocationSizeInformation(File <%wZ>, AllocationSize %d %d)\n", &Fcb->PathNameU,
AllocationSize->HighPart, AllocationSize->LowPart);
if (Fcb->Flags & FCB_IS_FATX_ENTRY)
OldSize = Fcb->entry.FatX.FileSize;
+1 -1
View File
@@ -120,7 +120,7 @@ CcPurgeCacheSection (
IN BOOLEAN UninitializeCacheMaps
)
{
UNIMPLEMENTED;
//UNIMPLEMENTED;
return FALSE;
}