[NTOS/MM] Do not error when FS returns STATUS_END_OF_FILE for paged read.

Also remove a seemingly invalid ASSERT
This commit is contained in:
Jérôme Gardou 2020-11-18 12:14:41 +01:00
parent b46173edaf
commit d440434a8e

View file

@ -1209,6 +1209,11 @@ MiReadPage(PMEMORY_AREA MemoryArea,
MmUnmapLockedPages (Mdl->MappedSystemVa, Mdl); MmUnmapLockedPages (Mdl->MappedSystemVa, Mdl);
} }
if (Status == STATUS_END_OF_FILE)
{
Status = STATUS_SUCCESS;
}
return Status; return Status;
} }
@ -2211,7 +2216,7 @@ MmCreateDataFileSection(PSECTION *SectionObject,
if (!GotFileHandle) if (!GotFileHandle)
{ {
ASSERT(UMaximumSize != NULL); ASSERT(UMaximumSize != NULL);
ASSERT(UMaximumSize->QuadPart != 0); // ASSERT(UMaximumSize->QuadPart != 0);
MaximumSize = *UMaximumSize; MaximumSize = *UMaximumSize;
} }
else else