From 12f667806eb0db0d3d207db65a848677d692d8c3 Mon Sep 17 00:00:00 2001 From: Eric Buehler <65165915+EricLBuehler@users.noreply.github.com> Date: Mon, 5 Dec 2022 08:42:23 -0500 Subject: [PATCH] Bug fixes for undefined behavior Relating to delete of pointer to local var --- builtins/lateincludebuiltins.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builtins/lateincludebuiltins.cpp b/builtins/lateincludebuiltins.cpp index 11d8aaf9..57acb4a3 100644 --- a/builtins/lateincludebuiltins.cpp +++ b/builtins/lateincludebuiltins.cpp @@ -55,7 +55,7 @@ object* builtin_eval(object* self, object* args){ } struct vm* vm_=::vm; - ::vm=new_vm(interpreter.vm_map->size(), code, compiler->instructions, &data); //data is still in scope... + ::vm=new_vm(interpreter.vm_map->size(), code, compiler->instructions, new string(data)); //data is still in scope... interpreter_add_vm(::vm->id, ::vm); ::vm->globals=glbls;