Permalink
Browse files

Mark `mrb->backtrace.exc` as GC root; fix #3388

  • Loading branch information...
matz committed Feb 4, 2017
1 parent 6e0ba00 commit 8e0f2313302871ddd713c3e8e6a9d4731426f308
Showing with 1 addition and 0 deletions.
  1. +1 −0 src/gc.c
View
@@ -857,6 +857,7 @@ root_scan_phase(mrb_state *mrb, mrb_gc *gc)
mrb_gc_mark(mrb, (struct RBasic*)mrb->top_self);
/* mark exception */
mrb_gc_mark(mrb, (struct RBasic*)mrb->exc);
mrb_gc_mark(mrb, (struct RBasic*)mrb->backtrace.exc);
/* mark pre-allocated exception */
mrb_gc_mark(mrb, (struct RBasic*)mrb->nomem_err);
#ifdef MRB_GC_FIXED_ARENA

0 comments on commit 8e0f231

Please sign in to comment.