From 5e5991ce19e9b89fb221432a41e423731b5373bb Mon Sep 17 00:00:00 2001 From: Jonas 'Sortie' Termansen Date: Fri, 2 Mar 2012 13:45:33 +0100 Subject: [PATCH] Fixed x86 addrspace destroy code calling Page::Put with garbage. --- sortix/x86/memorymanagement.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/sortix/x86/memorymanagement.cpp b/sortix/x86/memorymanagement.cpp index 6ec94507..4394e1e6 100644 --- a/sortix/x86/memorymanagement.cpp +++ b/sortix/x86/memorymanagement.cpp @@ -144,8 +144,13 @@ namespace Sortix addr_t fractal1 = PMLS[2]->entry[1022]; +#if 1 + Page::Put(fractal1 & PML_ADDRESS); + Page::Put(currentdir & PML_ADDRESS); +#else Page::Put(fractal1); Page::Put(currentdir); +#endif // Switch to the address space from when the world was originally // created. It should contain the kernel, the whole kernel, and