mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* thread.c (rb_thread_execute_interrupts): invoke ensure when
main thread exits. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12470 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
6f9ded1fb0
commit
72734ac154
2 changed files with 6 additions and 10 deletions
|
@ -1,3 +1,8 @@
|
|||
Thu Jun 7 21:38:39 2007 Koichi Sasada <ko1@atdot.net>
|
||||
|
||||
* thread.c (rb_thread_execute_interrupts): invoke ensure when
|
||||
main thread exits.
|
||||
|
||||
Thu Jun 7 19:02:48 2007 Tanaka Akira <akr@fsij.org>
|
||||
|
||||
* lib/pp.rb: call original "method" method instead of redefined one.
|
||||
|
|
11
thread.c
11
thread.c
|
@ -700,16 +700,7 @@ rb_thread_execute_interrupts(rb_thread_t *th)
|
|||
th->thrown_errinfo = 0;
|
||||
thread_debug("rb_thread_execute_interrupts: %ld\n", err);
|
||||
|
||||
if (err == eKillSignal) {
|
||||
th->errinfo = INT2FIX(TAG_FATAL);
|
||||
TH_JUMP_TAG(th, TAG_FATAL);
|
||||
}
|
||||
else if (err == eTerminateSignal) {
|
||||
/* rewind to toplevel stack */
|
||||
while (th->tag->prev) {
|
||||
th->tag = th->tag->prev;
|
||||
}
|
||||
|
||||
if (err == eKillSignal || err == eTerminateSignal) {
|
||||
th->errinfo = INT2FIX(TAG_FATAL);
|
||||
TH_JUMP_TAG(th, TAG_FATAL);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue