From 7138399f962dfdaefb1a305cd47a2102aae51996 Mon Sep 17 00:00:00 2001 From: Paul Kulchenko Date: Fri, 10 Nov 2023 18:37:00 -0800 Subject: [PATCH] Close Lua state before exiting redbean worker to allow GC to collect (#941) --- tool/net/redbean.c | 1 + 1 file changed, 1 insertion(+) diff --git a/tool/net/redbean.c b/tool/net/redbean.c index d6e330a10a8..c08e0de07b6 100644 --- a/tool/net/redbean.c +++ b/tool/net/redbean.c @@ -6556,6 +6556,7 @@ static int ExitWorker(void) { monitorth = 0; } } + LuaDestroy(); _Exit(0); }