You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In LuaObject's contructors and assignment operators, if src LuaObject happens to come from a coroutine then this LuaObject LuaState L will point to freed memory once the coroutine is garbage collected. Which results in all kinds of nasty business, especially in production code :(
From reading the reference, it appears that using lua_pushthread's return value of 1 for a non-coroutine lua_State should help identify that case and lua_xmove should transfer the object for a proper fastref in this's LuaObject's LuaState.
In LuaObject's contructors and assignment operators, if src LuaObject happens to come from a coroutine then this LuaObject LuaState L will point to freed memory once the coroutine is garbage collected. Which results in all kinds of nasty business, especially in production code :(
From reading the reference, it appears that using lua_pushthread's return value of 1 for a non-coroutine lua_State should help identify that case and lua_xmove should transfer the object for a proper fastref in this's LuaObject's LuaState.
luaplus51-all/Src/LuaPlus/LuaObject.inl
Lines 76 to 89 in 7eb904c
The text was updated successfully, but these errors were encountered: