mirror of
https://github.com/haproxy/haproxy.git
synced 2026-06-10 17:32:03 -04:00
BUG/MEDIUM: tcpcheck/server: Fix parsing of healthcheck param for dynamic servers
The parsing of the "healthcheck" parameter for dynamic servers was not finished. The post-config was missing, leading to a crash because the ruleset pointer was NULL. To fix the issue, check_server_tcpcheck() function is called in cli_parse_add_server(). No backport needed.
This commit is contained in:
parent
09c37fb6bd
commit
774d0dfe14
1 changed files with 5 additions and 0 deletions
|
|
@ -6271,6 +6271,11 @@ static int cli_parse_add_server(char **args, char *payload, struct appctx *appct
|
|||
/* ensure minconn/maxconn consistency */
|
||||
srv_minmax_conn_apply(srv);
|
||||
|
||||
errcode |= check_server_tcpcheck(srv);
|
||||
if (errcode & (ERR_ABORT|ERR_FATAL))
|
||||
goto out;
|
||||
|
||||
|
||||
if (srv->use_ssl == 1 || (srv->check.tcpcheck->flags & TCPCHK_FL_USE_SSL) ||
|
||||
srv->check.use_ssl == 1) {
|
||||
if (xprt_get(XPRT_SSL) && xprt_get(XPRT_SSL)->prepare_srv) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue