From: Christopher Faulet Date: Wed, 3 Jun 2020 17:00:42 +0000 (+0200) Subject: BUG/MINOR: checks: Fix test on http-check rulesets during config validity check X-Git-Tag: v2.2-dev9~155 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=c0fcbe4150c7fe3dbdbe3d65b3bd9b691aef3ea2;p=thirdparty%2Fhaproxy.git BUG/MINOR: checks: Fix test on http-check rulesets during config validity check When checking the config validity of the http-check rulesets, the test on the ruleset type is inverted. So a warning about ignored directive is emitted when the config is valid and omitted when it should be reported. No backport needed. --- diff --git a/src/cfgparse.c b/src/cfgparse.c index 2f0688a4bc..56f95581a5 100644 --- a/src/cfgparse.c +++ b/src/cfgparse.c @@ -2511,7 +2511,7 @@ int check_config_validity() } if ((curproxy->options2 & PR_O2_CHK_ANY) == PR_O2_TCPCHK_CHK && - (curproxy->tcpcheck_rules.flags & TCPCHK_RULES_PROTO_CHK) == TCPCHK_RULES_HTTP_CHK) { + (curproxy->tcpcheck_rules.flags & TCPCHK_RULES_PROTO_CHK) != TCPCHK_RULES_HTTP_CHK) { if (curproxy->options & PR_O_DISABLE404) { ha_warning("config : '%s' will be ignored for %s '%s' (requires 'option httpchk').\n", "disable-on-404", proxy_type_str(curproxy), curproxy->id);