BUG/MEDIUM: lua: cannot process more Lua hooks after a "done()" function call

When the Lua execution flow endswith the command done (core.done or txn.done())
an error is detourned, and the stack is no longer usable. This patch juste
reinitilize the stack if this case is detected.
This commit is contained in:
Thierry FOURNIER 2015-08-28 09:54:13 +02:00 committed by Willy Tarreau
parent 0458b08a5a
commit e1587b3314

View File

@ -1000,6 +1000,7 @@ timeout_reached:
*/
if (lua->flags & HLUA_EXIT) {
ret = HLUA_E_OK;
hlua_ctx_renew(lua, 0);
break;
}