[NTOSKRNL]

If the cache wasn't initialized by the FSD serving the image, don't allow section creation to avoid later (dramatic) failure in CC.

Based on a patch by Sylvain Deverre.

CORE-10038 #comment Modified patch committed in r70756

svn path=/trunk/; revision=70756
This commit is contained in:
Pierre Schweitzer 2016-02-15 21:22:05 +00:00
parent eacfcdff7c
commit 515de755e6

View file

@ -3777,6 +3777,14 @@ MmCreateImageSection(PROS_SECTION_OBJECT *SectionObject,
if (FileObject == NULL) if (FileObject == NULL)
return STATUS_INVALID_FILE_FOR_SECTION; return STATUS_INVALID_FILE_FOR_SECTION;
#ifndef NEWCC
if (FileObject->SectionObjectPointer->SharedCacheMap == NULL)
{
DPRINT1("Denying section creation due to missing cache initialization\n");
return STATUS_INVALID_FILE_FOR_SECTION;
}
#endif
/* /*
* Create the section * Create the section
*/ */