svn commit: r281978 - stable/10/sys/kern
Konstantin Belousov
kib at FreeBSD.org
Sat Apr 25 08:03:37 UTC 2015
Author: kib
Date: Sat Apr 25 08:03:36 2015
New Revision: 281978
URL: https://svnweb.freebsd.org/changeset/base/281978
Log:
MFC r281883:
Handle incorrect ELF images specifying size for PT_GNU_STACK not being
multiple of page size.
Modified:
stable/10/sys/kern/kern_exec.c
Directory Properties:
stable/10/ (props changed)
Modified: stable/10/sys/kern/kern_exec.c
==============================================================================
--- stable/10/sys/kern/kern_exec.c Sat Apr 25 06:50:15 2015 (r281977)
+++ stable/10/sys/kern/kern_exec.c Sat Apr 25 08:03:36 2015 (r281978)
@@ -1089,7 +1089,7 @@ exec_new_vmspace(imgp, sv)
/* Allocate a new stack */
if (imgp->stack_sz != 0) {
- ssiz = imgp->stack_sz;
+ ssiz = trunc_page(imgp->stack_sz);
PROC_LOCK(p);
lim_rlimit(p, RLIMIT_STACK, &rlim_stack);
PROC_UNLOCK(p);
More information about the svn-src-stable-10
mailing list