summaryrefslogtreecommitdiff
path: root/iseq.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2019-04-11 10:36:36 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2019-04-11 10:36:36 +0000
commit47c82df27ff73c5181f7bd4505b4c98a96f15a0c (patch)
tree5f7b5ede27e5def92ac7772cef35995d4ffd9cea /iseq.c
parentcf781b0871cb8d6b7135fa74d9549ca1cdb2a846 (diff)
Share the exception local ID table
[Fix GH-2115] From: Lourens Naudé <lourens@bearmetal.eu> git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@67511 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'iseq.c')
-rw-r--r--iseq.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/iseq.c b/iseq.c
index 99e626f8df..67fc862a33 100644
--- a/iseq.c
+++ b/iseq.c
@@ -91,7 +91,8 @@ rb_iseq_free(const rb_iseq_t *iseq)
#if VM_INSN_INFO_TABLE_IMPL == 2
if (body->insns_info.succ_index_table) ruby_xfree(body->insns_info.succ_index_table);
#endif
- ruby_xfree((void *)body->local_table);
+ if (LIKELY(body->local_table != rb_iseq_shared_exc_local_tbl))
+ ruby_xfree((void *)body->local_table);
ruby_xfree((void *)body->is_entries);
if (body->ci_entries) {