Bug fixes
This commit is contained in:
7
vm.c
7
vm.c
@@ -63,9 +63,10 @@ do_getglobal:;
|
||||
|
||||
regset->regs[inst->a] = ltable_get(func->env, lvalue_from_string(str));
|
||||
|
||||
set_LValueU_insert(heap, lvalue_from_string(str).u);
|
||||
free(str);
|
||||
|
||||
lvm_gc_alert(L, &privates, sizeof(*str) + len);
|
||||
//set_LValueU_insert(heap, lvalue_from_string(str).u);
|
||||
//lvm_gc_alert(L, &privates, sizeof(*str) + len);
|
||||
}
|
||||
DISPATCH();
|
||||
|
||||
@@ -421,7 +422,7 @@ static void gc_mark(LValue v) {
|
||||
}
|
||||
static void gc_mark_units(LVM *L) {
|
||||
for(size_t u = 0; u < L->unit_count; u++) {
|
||||
LUnit *unit = &L->units[u];
|
||||
LUnit *unit = L->units[u];
|
||||
for(size_t f = 0; f < unit->func_count; f++) {
|
||||
LFunc *func = &unit->funcs[f];
|
||||
gc_mark(lvalue_from_table(func->env));
|
||||
|
||||
Reference in New Issue
Block a user