Should update ci->env to share the environment; fix #4073

This commit is contained in:
Yukihiro "Matz" Matsumoto
2018-08-01 10:08:40 +09:00
parent 8558627b9b
commit e89cc9b9fa
+1
View File
@@ -254,6 +254,7 @@ create_proc_from_string(mrb_state *mrb, char *s, mrb_int len, mrb_value binding,
if (ci->argc < 0) bidx = 2;
else bidx += 1;
MRB_ENV_SET_BIDX(e, bidx);
ci->env = e;
}
proc->e.env = e;
proc->flags |= MRB_PROC_ENVSET;