FFI: Turn FFI finalizer table into a proper GC root.
Reported by Sergey Bronnikov. #1168
This commit is contained in:
@@ -196,6 +196,9 @@ static TValue *cpluaopen(lua_State *L, lua_CFunction dummy, void *ud)
|
||||
lj_lex_init(L);
|
||||
fixstring(lj_err_str(L, LJ_ERR_ERRMEM)); /* Preallocate memory error msg. */
|
||||
g->gc.threshold = 4*g->gc.total;
|
||||
#if LJ_HASFFI
|
||||
lj_ctype_initfin(L);
|
||||
#endif
|
||||
lj_trace_initstate(g);
|
||||
lj_err_verify();
|
||||
return NULL;
|
||||
|
||||
Reference in New Issue
Block a user