Some lua state allocator fixes
Run GC on the themeroom lua states, as they're not freed until end of game. Allocate the exact amount of data we use instead of padding it. Free our state data after closing the lua state; doing it the other way is the way to madness, which was kept at bay by the padded allocation amount.
This commit is contained in:
@@ -335,6 +335,7 @@ makerooms(void)
|
||||
wallification(1, 0, COLNO - 1, ROWNO - 1);
|
||||
free(gc.coder);
|
||||
gc.coder = NULL;
|
||||
lua_gc(themes, LUA_GCCOLLECT);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user