From: Thierry FOURNIER / OZON.IO Date: Sat, 12 Nov 2016 12:11:47 +0000 (+0100) Subject: CLEANUP: lua: control executed twice X-Git-Tag: v1.7.0~92 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b41f22f59cbe08f00529d3d3ad8a233e3c0d7adc;p=thirdparty%2Fhaproxy.git CLEANUP: lua: control executed twice The availaible size in the stack is check two times. This patch removes this double check. Must be backported in 1.6 --- diff --git a/src/hlua.c b/src/hlua.c index 5a1785de56..deff4cc830 100644 --- a/src/hlua.c +++ b/src/hlua.c @@ -5378,11 +5378,6 @@ static int hlua_sample_fetch_wrapper(const struct arg *arg_p, struct sample *smp RESET_SAFE_LJMP(stream->hlua.T); return 0; } - if (!lua_checkstack(stream->hlua.T, 1)) { - SEND_ERR(smp->px, "Lua sample-fetch '%s': full stack.\n", fcn->name); - RESET_SAFE_LJMP(stream->hlua.T); - return 0; - } hlua_arg2lua(stream->hlua.T, arg_p); stream->hlua.nargs++; }