2011-01-29 00:21:13 +00:00
|
|
|
--- a/libpthread/nptl/init.c
|
|
|
|
+++ b/libpthread/nptl/init.c
|
2011-04-17 17:38:35 +00:00
|
|
|
@@ -402,6 +402,10 @@ __pthread_initialize_minimal_internal (v
|
2011-01-29 00:21:13 +00:00
|
|
|
Use the minimal size acceptable. */
|
|
|
|
limit.rlim_cur = PTHREAD_STACK_MIN;
|
|
|
|
|
|
|
|
+ /* Do not exceed architecture specific default */
|
|
|
|
+ if (limit.rlim_cur > ARCH_STACK_DEFAULT_SIZE)
|
|
|
|
+ limit.rlim_cur = ARCH_STACK_DEFAULT_SIZE;
|
|
|
|
+
|
|
|
|
/* Make sure it meets the minimum size that allocate_stack
|
|
|
|
(allocatestack.c) will demand, which depends on the page size. */
|
|
|
|
const uintptr_t pagesz = sysconf (_SC_PAGESIZE);
|