From b652d802f5927f4b5efe253b99c4bb4773fbcfa7 Mon Sep 17 00:00:00 2001 From: Alug Date: Fri, 15 May 2026 01:08:53 +0200 Subject: [PATCH] blua: fix copy paste error for "slow path" in auxgetstr/lua_getfield lets hope this fixes the random crashes from gc sometime stimky from https://github.com/Indev450/SRB2Kart-Saturn/pull/223/changes/e4e51f0f80fb7deb9213c72bb374d0a7e4c3f03b --- src/blua/lapi.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/blua/lapi.c b/src/blua/lapi.c index bca24a90f..e494e9fc9 100644 --- a/src/blua/lapi.c +++ b/src/blua/lapi.c @@ -526,13 +526,12 @@ static void auxgetstr (lua_State *L, TValue *t, const char *k) { api_checkvalidindex(L, t); if (luaV_fastget(L, t, str, slot, luaH_getstr)) { setobj2s(L, L->top, slot); - api_incr_top(L); } else { setsvalue(L, &key, str); - luaV_finishget(L, t, L->top, L->top, slot); - api_incr_top(L); + luaV_finishget(L, t, &key, L->top, slot); } + api_incr_top(L); lua_unlock(L); }