[Glibc-bsd-commits] r5128 - trunk/glibc-ports/fbtl

Petr Salinger ps-guest at alioth.debian.org
Thu Nov 7 08:20:49 UTC 2013


Author: ps-guest
Date: 2013-11-07 08:20:48 +0000 (Thu, 07 Nov 2013)
New Revision: 5128

Modified:
   trunk/glibc-ports/fbtl/nptl-init.c
Log:
limit default stack size to 4 * ARCH_STACK_DEFAULT_SIZE


Modified: trunk/glibc-ports/fbtl/nptl-init.c
===================================================================
--- trunk/glibc-ports/fbtl/nptl-init.c	2013-11-06 10:29:43 UTC (rev 5127)
+++ trunk/glibc-ports/fbtl/nptl-init.c	2013-11-07 08:20:48 UTC (rev 5128)
@@ -429,6 +429,10 @@
     /* The system limit is unusably small.
        Use the minimal size acceptable.  */
     limit.rlim_cur = PTHREAD_STACK_MIN;
+  else if (limit.rlim_cur > (4 * ARCH_STACK_DEFAULT_SIZE))
+    /* The system limit is unusably high.
+       Use the maximal size acceptable.  */
+    limit.rlim_cur = (4 * ARCH_STACK_DEFAULT_SIZE);
 
   /* Make sure it meets the minimum size that allocate_stack
      (allocatestack.c) will demand, which depends on the page size.  */




More information about the Glibc-bsd-commits mailing list