Make Memory::Lookup return false on unmapped pages.

This commit is contained in:
Jonas 'Sortie' Termansen 2013-01-12 15:16:19 +01:00
parent a685a9d68f
commit b0c01f2c6a
1 changed files with 2 additions and 0 deletions

View File

@ -440,6 +440,8 @@ namespace Sortix
}
addr_t entry = (PMLS[1] + offset)->entry[pmlchildid[1]];
if ( !(entry & PML_PRESENT) ) { return false; }
int entryflags = entry & PML_ADDRESS;
int entryprot = PMLFlagsToProtection(entryflags);
prot &= entryprot;