diff options
author | Benoit Germain <benoit.germain@ubisoft.com> | 2024-04-29 15:53:25 +0200 |
---|---|---|
committer | Benoit Germain <benoit.germain@ubisoft.com> | 2024-04-29 15:53:25 +0200 |
commit | dd4a6ece589ca49130f2adf29d38af678f1640a9 (patch) | |
tree | cb0c6530e8848252159b90e05de471144d786ad1 | |
parent | 3e3805297301b15f688297c9c7f65153aec86818 (diff) | |
download | lanes-dd4a6ece589ca49130f2adf29d38af678f1640a9.tar.gz lanes-dd4a6ece589ca49130f2adf29d38af678f1640a9.tar.bz2 lanes-dd4a6ece589ca49130f2adf29d38af678f1640a9.zip |
Fix keeper state stack integrity assertion
Diffstat (limited to '')
-rw-r--r-- | src/deep.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/deep.cpp b/src/deep.cpp index 10f589e..af7e814 100644 --- a/src/deep.cpp +++ b/src/deep.cpp | |||
@@ -174,7 +174,11 @@ void DeepFactory::DeleteDeepObject(lua_State* L_, DeepPrelude* o_) | |||
174 | lua_insert( L_, -2); // __gc self | 174 | lua_insert( L_, -2); // __gc self |
175 | lua_call( L_, 1, 0); // | 175 | lua_call( L_, 1, 0); // |
176 | } | 176 | } |
177 | // we don't really know what remains on the stack at that point (depending on us finding a __gc or not), but we don't care | 177 | else |
178 | { | ||
179 | // need an empty stack in case we are GC_ing from a Keeper, so that empty stack checks aren't triggered | ||
180 | lua_pop(L_, 2); | ||
181 | } | ||
178 | DeepFactory::DeleteDeepObject(L_, p); | 182 | DeepFactory::DeleteDeepObject(L_, p); |
179 | } | 183 | } |
180 | return 0; | 184 | return 0; |