Fix lua crash in cleanup
parent
6b856b3352
commit
318b4378a9
|
@ -266,6 +266,9 @@ static void checkTimeslice(lua_State* l, lua_Debug* /*ar*/)
|
||||||
// allow the script to perform cleanup
|
// allow the script to perform cleanup
|
||||||
void LuaState::cleanup()
|
void LuaState::cleanup()
|
||||||
{
|
{
|
||||||
|
if (!costate)
|
||||||
|
return;
|
||||||
|
|
||||||
if (ioMode == Asking)
|
if (ioMode == Asking)
|
||||||
{
|
{
|
||||||
// Restore renderflags:
|
// Restore renderflags:
|
||||||
|
|
Loading…
Reference in New Issue