зеркало из https://github.com/github/ruby.git
thread_pthread.c: adjust stack size
* thread_pthread.c (ruby_init_stack): adjust stack size for offset of addr from the bottom. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36013 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
8fdd48d69f
Коммит
35c96b9003
|
@ -1,3 +1,8 @@
|
|||
Sun Jun 10 17:54:26 2012 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||
|
||||
* thread_pthread.c (ruby_init_stack): adjust stack size for offset of
|
||||
addr from the bottom.
|
||||
|
||||
Sun Jun 10 15:49:47 2012 Tanaka Akira <akr@fsij.org>
|
||||
|
||||
* process.c (retry_fork): call after_fork except in a child process.
|
||||
|
|
|
@ -608,8 +608,9 @@ ruby_init_stack(volatile VALUE *addr
|
|||
size_t size = 0;
|
||||
size_t space = 0;
|
||||
#if defined(STACKADDR_AVAILABLE)
|
||||
void* addr;
|
||||
get_stack(&addr, &size);
|
||||
void* stackaddr;
|
||||
get_stack(&stackaddr, &size);
|
||||
space = STACK_DIR_UPPER((char *)addr - (char *)stackaddr, (char *)stackaddr - (char *)addr);
|
||||
#elif defined(HAVE_GETRLIMIT)
|
||||
struct rlimit rlim;
|
||||
if (getrlimit(RLIMIT_STACK, &rlim) == 0) {
|
||||
|
|
Загрузка…
Ссылка в новой задаче