BUG/MINOR: hlua/init: coroutine may not resume itself
authorAurelien DARRAGON <adarragon@haproxy.com>
Fri, 8 Sep 2023 17:29:08 +0000 (19:29 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Tue, 12 Sep 2023 17:50:17 +0000 (19:50 +0200)
commit1115fc348ec4a7d25ecc316ccc41e2f00c95259c
tree962fd6ff6d9493a0c263e639dad35e622347e6eb
parente7281f3f5d5b0b34e5c7e52ecb12255545255e1b
BUG/MINOR: hlua/init: coroutine may not resume itself

It's not supported to call lua_resume with <L> and <from> designating
the same lua coroutine. It didn't cause visible bugs so far because
Lua 5.3 used to be more permissive about this, and moreover, yielding
is not involved during the hlua init state.

But this is wrong usage, and the doc clearly specifies that the <from>
argument can be NULL when there is no such coroutine, which is the case
here.

This should be backported in every stable versions.
src/hlua.c