From 431b9dbd009f47458cd502784fad01983e656ce0 Mon Sep 17 00:00:00 2001 From: usa Date: Tue, 29 Sep 2015 08:22:42 +0000 Subject: merge revision(s) 51626: [Backport #11457] * thread_pthread.c (reserve_stack): ensure the memory is really allocated. [Bug #11457] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_2_1@51975 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- thread_pthread.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'thread_pthread.c') diff --git a/thread_pthread.c b/thread_pthread.c index ed4880c40c..968c644897 100644 --- a/thread_pthread.c +++ b/thread_pthread.c @@ -681,8 +681,8 @@ reserve_stack(volatile char *limit, size_t size) limit -= size; if (buf > limit) { limit = alloca(buf - limit); + limit[0] = 0; /* ensure alloca is called */ limit -= stack_check_margin; - limit[0] = 0; } } } -- cgit v1.2.3