diff --git a/src/lj_clib.c b/src/lj_clib.c index dc72dced..41a8738e 100644 --- a/src/lj_clib.c +++ b/src/lj_clib.c @@ -364,6 +364,7 @@ TValue *lj_clib_index(lua_State *L, CLibrary *cl, GCstr *name) cd = lj_cdata_new(cts, id, CTSIZE_PTR); *(void **)cdataptr(cd) = p; setcdataV(L, tv, cd); + lj_gc_anybarriert(L, cl->cache); } } return tv;