diff options
| -rw-r--r-- | vm.c | 2 | 
1 files changed, 1 insertions, 1 deletions
| @@ -266,7 +266,7 @@ deallocuvm(pde_t *pgdir, uint oldsz, uint newsz)    for(; a  < oldsz; a += PGSIZE){      pte = walkpgdir(pgdir, (char*)a, 0);      if(!pte) -      a += (NPTENTRIES - 1) * PGSIZE; +      a = PGADDR(PDX(a) + 1, 0, 0) - PGSIZE;      else if((*pte & PTE_P) != 0){        pa = PTE_ADDR(*pte);        if(pa == 0) | 
