patch-1.3.26 linux/mm/mmap.c
Next file: linux/mm/swap.c
Previous file: linux/mm/memory.c
Back to the patch index
Back to the overall index
- Lines: 26
- Date:
Tue Sep 12 12:49:48 1995
- Orig file:
v1.3.25/linux/mm/mmap.c
- Orig date:
Thu Sep 7 17:17:20 1995
diff -u --recursive --new-file v1.3.25/linux/mm/mmap.c linux/mm/mmap.c
@@ -231,6 +231,8 @@
#if 0 /* equivalent, but slow */
struct vm_area_struct * vma;
+ if (!task->mm)
+ return NULL;
for (vma = task->mm->mmap ; ; vma = vma->vm_next) {
if (!vma)
return NULL;
@@ -241,6 +243,8 @@
struct vm_area_struct * result = NULL;
struct vm_area_struct * tree;
+ if (!task->mm)
+ return NULL;
for (tree = task->mm->mmap_avl ; ; ) {
if (tree == avl_empty)
return result;
@@ -798,6 +802,7 @@
remove_shared_vm_struct(mpnt);
if (mpnt->vm_inode)
iput(mpnt->vm_inode);
+ zap_page_range(mm, mpnt->vm_start, mpnt->vm_end-mpnt->vm_start);
kfree(mpnt);
mpnt = next;
}
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov
with Sam's (original) version of this