mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
Exceptions in fibers must be re-raised via #resume; fix #3675
This commit is contained in:
@@ -1759,7 +1759,7 @@ RETRY_TRY_BLOCK:
|
||||
ci0 = ci = mrb->c->ci;
|
||||
eidx = ci->eidx;
|
||||
if (ci == mrb->c->cibase) {
|
||||
if (ci->ridx == 0) goto L_STOP;
|
||||
if (ci->ridx == 0) goto L_FTOP;
|
||||
goto L_RESCUE;
|
||||
}
|
||||
stk = mrb->c->stack;
|
||||
@@ -1774,6 +1774,7 @@ RETRY_TRY_BLOCK:
|
||||
if (ci == mrb->c->cibase) {
|
||||
mrb->c->stack = stk;
|
||||
if (ci->ridx == 0) {
|
||||
L_FTOP: /* fiber top */
|
||||
if (mrb->c == mrb->root_c) {
|
||||
mrb->c->stack = mrb->c->stbase;
|
||||
goto L_STOP;
|
||||
|
||||
Reference in New Issue
Block a user