Fixed MM_ClearUser not zeroing cleared entries
authorJohn Hodge <[email protected]>
Sun, 27 Sep 2009 07:43:41 +0000 (15:43 +0800)
committerJohn Hodge <[email protected]>
Sun, 27 Sep 2009 07:43:41 +0000 (15:43 +0800)
Kernel/arch/x86/mm_virt.c

index 2fec186..7db7ced 100644 (file)
@@ -386,10 +386,12 @@ Uint MM_ClearUser()
                }
                
                MM_DerefPhys( gaPageDir[i] & ~0xFFF );
+               gaPageDir[i] = 0;
+               INVLPG( &gaPageTable[i*1024] );
        }
+       INVLPG( gaPageDir );
        
-       
-       return *gTmpCR3;
+       return *gaPageCR3;
 }
 
 /**

UCC git Repository :: git.ucc.asn.au