зеркало из https://github.com/github/ruby.git
* thread.c (thread_join): Fixnum (except TAG_FATAL) and
NODE should not be reached here. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@49915 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
ab38e5b585
Коммит
04e348e61a
|
@ -1,3 +1,8 @@
|
|||
Tue Mar 10 17:27:27 2015 Koichi Sasada <ko1@atdot.net>
|
||||
|
||||
* thread.c (thread_join): Fixnum (except TAG_FATAL) and
|
||||
NODE should not be reached here.
|
||||
|
||||
Mon Mar 9 21:42:10 2015 Koichi Sasada <ko1@atdot.net>
|
||||
|
||||
* vm_insnhelper.c (ep_cref): rename to lep_cref() because it should be
|
||||
|
|
11
thread.c
11
thread.c
|
@ -884,11 +884,16 @@ thread_join(rb_thread_t *target_th, double delay)
|
|||
VALUE err = target_th->errinfo;
|
||||
|
||||
if (FIXNUM_P(err)) {
|
||||
/* */
|
||||
switch (err) {
|
||||
case INT2FIX(TAG_FATAL):
|
||||
/* OK. killed. */
|
||||
break;
|
||||
default:
|
||||
rb_bug("thread_join: Fixnum (%d) should not reach here.", FIX2INT(err));
|
||||
}
|
||||
}
|
||||
else if (RB_TYPE_P(target_th->errinfo, T_NODE)) {
|
||||
rb_exc_raise(rb_vm_make_jump_tag_but_local_jump(
|
||||
GET_THROWOBJ_STATE(err), GET_THROWOBJ_VAL(err)));
|
||||
rb_bug("thread_join: NODE should not reach here.");
|
||||
}
|
||||
else {
|
||||
/* normal exception */
|
||||
|
|
Загрузка…
Ссылка в новой задаче