diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-11-27 06:05:07 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-11-27 06:05:07 +0000 |
commit | 7348aa6113cdc2c9ce62044ab83f2ac1db82816d (patch) | |
tree | 67f6170252317e0ed1234217f5fb1a80c2592264 /thread.c | |
parent | fc75648baff072ec223d88fdb86b3384e22ea71f (diff) | |
download | ruby-7348aa6113cdc2c9ce62044ab83f2ac1db82816d.tar.gz |
* gc.c (ruby_stack_check): no check if using sigaltstack.
* signal.c (register_sigaltstack): minimum size is insufficient for
method calls.
* signal.c (sigsegv): handles stack overflow if possible.
* thread.c (ruby_thread_stack_overflow): helper function to raise
sysstack_error.
* thread_pthread.c (ruby_stack_overflowed_p): checks for stack
overflow.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@20372 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'thread.c')
-rw-r--r-- | thread.c | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -1184,6 +1184,14 @@ rb_thread_signal_exit(void *thptr) rb_thread_raise(2, argv, th->vm->main_thread); } +void +ruby_thread_stack_overflow(rb_thread_t *th) +{ + th->errinfo = sysstack_error; + th->raised_flag = 0; + TH_JUMP_TAG(th, TAG_RAISE); +} + int rb_thread_set_raised(rb_thread_t *th) { |