summaryrefslogtreecommitdiff
path: root/vm_backtrace.c
diff options
context:
space:
mode:
Diffstat (limited to 'vm_backtrace.c')
-rw-r--r--vm_backtrace.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/vm_backtrace.c b/vm_backtrace.c
index 5934029..0493ed8 100644
--- a/vm_backtrace.c
+++ b/vm_backtrace.c
@@ -1202,6 +1202,9 @@ rb_debug_inspector_open(rb_debug_inspector_func_t func, void *data)
enum ruby_tag_type state;
volatile VALUE MAYBE_UNUSED(result);
+ /* escape all env to heap */
+ rb_vm_stack_to_heap(ec);
+
dbg_context.ec = ec;
dbg_context.cfp = dbg_context.ec->cfp;
dbg_context.backtrace = ec_backtrace_location_ary(ec, 0, 0);