[FASTFAT]

Add support for more notifications on file modification.

CORE-2582

svn path=/trunk/; revision=62471
This commit is contained in:
Pierre Schweitzer
2014-03-11 07:22:28 +00:00
parent 32cd2f8ced
commit cb87e96df6
+16
View File
@@ -1000,6 +1000,8 @@ VfatWrite(
if(!(*Fcb->Attributes & FILE_ATTRIBUTE_DIRECTORY))
{
LARGE_INTEGER SystemTime;
ULONG Filter;
// set dates and times
KeQuerySystemTime (&SystemTime);
if (Fcb->Flags & FCB_IS_FATX_ENTRY)
@@ -1019,6 +1021,20 @@ VfatWrite(
}
/* set date and times to dirty */
Fcb->Flags |= FCB_IS_DIRTY;
/* Time to notify the OS */
Filter = FILE_NOTIFY_CHANGE_LAST_WRITE | FILE_NOTIFY_CHANGE_ATTRIBUTES;
if (ByteOffset.QuadPart != OldFileSize.QuadPart) Filter |= FILE_NOTIFY_CHANGE_SIZE;
FsRtlNotifyFullReportChange(IrpContext->DeviceExt->NotifySync,
&(IrpContext->DeviceExt->NotifyList),
(PSTRING)&Fcb->PathNameU,
Fcb->PathNameU.Length - Fcb->LongNameU.Length,
NULL,
NULL,
Filter,
FILE_ACTION_MODIFIED,
NULL);
}
}