diff options
Diffstat (limited to 'src/lj_api.c')
-rw-r--r-- | src/lj_api.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/lj_api.c b/src/lj_api.c index d4048d79..1ad71678 100644 --- a/src/lj_api.c +++ b/src/lj_api.c | |||
@@ -1052,6 +1052,7 @@ LUA_API int lua_setmetatable(lua_State *L, int idx) | |||
1052 | /* Flush cache, since traces specialize to basemt. But not during __gc. */ | 1052 | /* Flush cache, since traces specialize to basemt. But not during __gc. */ |
1053 | if (lj_trace_flushall(L)) | 1053 | if (lj_trace_flushall(L)) |
1054 | lj_err_caller(L, LJ_ERR_NOGCMM); | 1054 | lj_err_caller(L, LJ_ERR_NOGCMM); |
1055 | o = index2adr(L, idx); /* Stack may have been reallocated. */ | ||
1055 | if (tvisbool(o)) { | 1056 | if (tvisbool(o)) { |
1056 | /* NOBARRIER: basemt is a GC root. */ | 1057 | /* NOBARRIER: basemt is a GC root. */ |
1057 | setgcref(basemt_it(g, LJ_TTRUE), obj2gco(mt)); | 1058 | setgcref(basemt_it(g, LJ_TTRUE), obj2gco(mt)); |