summaryrefslogtreecommitdiffstats
path: root/sys/vm/vm_map.c
diff options
context:
space:
mode:
authoralc <alc@FreeBSD.org>2003-12-26 21:54:45 +0000
committeralc <alc@FreeBSD.org>2003-12-26 21:54:45 +0000
commit2ce64279e54710912cdac619afa147ca8937c3ac (patch)
treeb38a30342221d2422cfb71a0198183e22bb92028 /sys/vm/vm_map.c
parentc6baaab59030b49ae2123ddab17aec323f1f7263 (diff)
downloadFreeBSD-src-2ce64279e54710912cdac619afa147ca8937c3ac.zip
FreeBSD-src-2ce64279e54710912cdac619afa147ca8937c3ac.tar.gz
Minor correction to revision 1.258: Use the proc pointer that is passed to
vm_map_growstack() in the RLIMIT_VMEM check rather than curthread.
Diffstat (limited to 'sys/vm/vm_map.c')
-rw-r--r--sys/vm/vm_map.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/sys/vm/vm_map.c b/sys/vm/vm_map.c
index 671cbac..1572cbc 100644
--- a/sys/vm/vm_map.c
+++ b/sys/vm/vm_map.c
@@ -2677,8 +2677,7 @@ Retry:
}
/* If we would blow our VMEM resource limit, no go */
- if (map->size + grow_amount >
- curthread->td_proc->p_rlimit[RLIMIT_VMEM].rlim_cur) {
+ if (map->size + grow_amount > p->p_rlimit[RLIMIT_VMEM].rlim_cur) {
vm_map_unlock_read(map);
return (KERN_NO_SPACE);
}
OpenPOWER on IntegriCloud