mirror of
https://github.com/reactos/reactos.git
synced 2025-02-24 09:25:10 +00:00
halfplement MmCanFileBeTruncated
svn path=/trunk/; revision=39289
This commit is contained in:
parent
a120dfab47
commit
cfad1c5307
1 changed files with 24 additions and 1 deletions
|
@ -4714,8 +4714,31 @@ BOOLEAN NTAPI
|
||||||
MmCanFileBeTruncated (IN PSECTION_OBJECT_POINTERS SectionObjectPointer,
|
MmCanFileBeTruncated (IN PSECTION_OBJECT_POINTERS SectionObjectPointer,
|
||||||
IN PLARGE_INTEGER NewFileSize)
|
IN PLARGE_INTEGER NewFileSize)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
/* Check whether an ImageSectionObject exists */
|
||||||
|
if (SectionObjectPointer->ImageSectionObject != NULL)
|
||||||
|
{
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (SectionObjectPointer->DataSectionObject != NULL)
|
||||||
|
{
|
||||||
|
PMM_SECTION_SEGMENT Segment;
|
||||||
|
|
||||||
|
Segment = (PMM_SECTION_SEGMENT)SectionObjectPointer->
|
||||||
|
DataSectionObject;
|
||||||
|
|
||||||
|
if (Segment->ReferenceCount != 0)
|
||||||
|
{
|
||||||
|
/* FIXME: check if NewFileSize <= current file size */
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* FIXME: check for outstanding write probes */
|
||||||
UNIMPLEMENTED;
|
UNIMPLEMENTED;
|
||||||
return (FALSE);
|
|
||||||
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue