aboutsummaryrefslogtreecommitdiff
path: root/mm/nommu.c
diff options
context:
space:
mode:
authorBen Dooks <ben-linux@fluff.org>2008-11-03 14:49:01 +0000
committerBen Dooks <ben-linux@fluff.org>2008-11-03 14:49:01 +0000
commite856359685143a2f65876e7db4e4aa0ef5dce7f0 (patch)
treebbcafe7f23975979f7a2bc6fd1404908d5fd7bd1 /mm/nommu.c
parente3bd9ec5d8bfc90f9e1bd995677829e57a404061 (diff)
parent45beca08dd8b6d6a65c5ffd730af2eac7a2c7a03 (diff)
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6 into s3c-moves2
Diffstat (limited to 'mm/nommu.c')
-rw-r--r--mm/nommu.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/mm/nommu.c b/mm/nommu.c
index 2696b24f2bb..7695dc85078 100644
--- a/mm/nommu.c
+++ b/mm/nommu.c
@@ -1454,7 +1454,8 @@ int __vm_enough_memory(struct mm_struct *mm, long pages, int cap_sys_admin)
/* Don't let a single process grow too big:
leave 3% of the size of this process for other processes */
- allowed -= current->mm->total_vm / 32;
+ if (mm)
+ allowed -= mm->total_vm / 32;
/*
* cast `allowed' as a signed long because vm_committed_space