[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: segmentation fault in luaG_findlocal
- From: Roberto Ierusalimschy <roberto@...>
- Date: Fri, 1 Sep 2023 11:33:25 -0300
> on the latest version of Lua source code (commit hash
> 9b4f39ab14fb2e55345c3d23537d129dac23b091)
>
> I've discovered segmentation fault on access to a local variable with
> non-existent index.
>
> Assume we have a snippet (lua_getlocal.c) written using Lua C:
>
> [...]
> lua_Debug ar;
> lua_getlocal(L, &ar, 100);
> lua_close(L);
You cannot call 'lua_getlocal' with an uninitialized 'ar'. Check the
documentation for more details.
-- Roberto