diff options
author | NAKAMURA Usaku <usa@ruby-lang.org> | 2022-03-19 22:15:40 +0900 |
---|---|---|
committer | NAKAMURA Usaku <usa@ruby-lang.org> | 2022-03-19 22:15:40 +0900 |
commit | ea9b0fe5d30efaa7dad1be4da79c1ee58f4f963b (patch) | |
tree | c630cd0a821f604739993dc9ce708c83981695ce /thread.c | |
parent | 83de7133876ec392eb4b3b69c2220d7b49685444 (diff) |
merge revision(s) ae5458f228a5477383e9c00425d85d50a3867817: [Backport #18475]
thread.c: Convert TAG_BREAK to a normal exception at thread top-level
[Bug #18475]
---
test/ruby/test_enum.rb | 11 +++++++++++
thread.c | 3 +++
2 files changed, 14 insertions(+)
Diffstat (limited to 'thread.c')
-rw-r--r-- | thread.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -741,6 +741,10 @@ thread_start_func_2(rb_thread_t *th, VALUE *stack_start) } else { errinfo = th->ec->errinfo; + + VALUE exc = rb_vm_make_jump_tag_but_local_jump(state, Qundef); + if (!NIL_P(exc)) errinfo = exc; + if (state == TAG_FATAL) { /* fatal error within this thread, need to stop whole script */ } |