Index: section.c =================================================================== --- ntoskrnl/mm/section.c (revision 74432) +++ ntoskrnl/mm/section.c (working copy) @@ -2708,7 +2708,12 @@ } else { - (void)InterlockedDecrementUL(&Section->Segment->ReferenceCount); + PMM_SECTION_SEGMENT Segment = Section->Segment; + if (InterlockedDecrementUL(&Segment->ReferenceCount) == 0) + { + Section->Segment = NULL; + MmFinalizeSegment(Segment); + } } } if (Section->FileObject != NULL)