From a135953b17e16dcc9a7be8d04cde2997a05f102e Mon Sep 17 00:00:00 2001 From: Lizongdi <1210855344@qq.com> Date: Wed, 9 Sep 2026 16:24:00 +0800 Subject: [PATCH] =?UTF-8?q?lua=E3=80=90=E4=B8=BB=E7=BA=BF=E5=BE=85?= =?UTF-8?q?=E5=90=88=E3=80=91=E8=A7=A3=E5=86=B3=E9=87=8A=E6=94=BE=E9=9D=9E?= =?UTF-8?q?=E7=A9=BA=E6=8C=87=E9=92=88=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lua/lauxlib.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lua/lauxlib.c b/lua/lauxlib.c index 08d4f4c..b66e06f 100644 --- a/lua/lauxlib.c +++ b/lua/lauxlib.c @@ -988,7 +988,7 @@ LUALIB_API const char *luaL_gsub (lua_State *L, const char *s, static void *l_alloc (void *ud, void *ptr, size_t osize, size_t nsize) { (void)ud; (void)osize; /* not used */ if (nsize == 0) { - RD_FREE(ptr); + if (ptr) RD_FREE(ptr); return NULL; } else