lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Do we have verification?
On Sun, Apr 10, 2016 at 15:07 Nagaev Boris <bnagaev@gmail.com> wrote:
On Sun, Apr 10, 2016 at 6:40 PM, Jura Pk <marsgpl@gmail.com> wrote:
> Problem solved, thanks to Shmuel Zeigerman and Soni L.
> After wrapping in lua_checkstack, the code works perfectly even with 1000
> tables.
> Seems, like lua_checkstack grows the stack =)
>
> 2016-04-10 21:27 GMT+03:00 Shmuel Zeigerman <shmuz@013net.net>:
>>
>> On 10/04/2016 20:16, Jura Pk wrote:
>>>
>>> I am stuck with a problem: when I'm trying to add 100 tables in Lua c
>>> stack, I receive segfault on function end.
>>> Code example:
>>> lua_example.c: http://pastebin.com/GFvLwMY2
>>> Makefile: http://pastebin.com/3EWJiVz7
>>> test.lua: http://pastebin.com/1y22XvzK
>>>
>>
>> See https://www.lua.org/manual/5.3/manual.html#lua_checkstack
>>
>> --
>> Shmuel
>>
>>
>

By the way, why not to grow the stack automatically in pushing API functions?

--


Best regards,
Boris Nagaev