From: Christopher Faulet Date: Tue, 28 Apr 2020 08:47:28 +0000 (+0200) Subject: BUG/MINOR: checks: Don't lose warning on proxy capability X-Git-Tag: v2.2-dev7~59 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=528f4811d60e6d9ec1cba167a9ab241142d6d9c7;p=thirdparty%2Fhaproxy.git BUG/MINOR: checks: Don't lose warning on proxy capability When a tcp-check line is parsed, a warning may be reported if the keyword is used for a frontend. The return value must be used to report it. But this info is lost before the end of the function. Partly fixes issue #600. No backport needed. --- diff --git a/src/checks.c b/src/checks.c index 183b42fc68..d1d5cdda02 100644 --- a/src/checks.c +++ b/src/checks.c @@ -5566,7 +5566,7 @@ static int proxy_parse_tcpcheck(char **args, int section, struct proxy *curpx, memprintf(errmsg, "'%s %s' : %s.", args[0], args[1], *errmsg); goto error; } - ret = (*errmsg != NULL); /* Handle warning */ + ret = (ret || (*errmsg != NULL)); /* Handle warning */ /* No error: add the tcp-check rule in the list */ chk->index = index;