From: Christopher Faulet Date: Mon, 6 Jul 2020 17:03:25 +0000 (+0200) Subject: MINOR: log: Remove unused case statement during the log-format string parsing X-Git-Tag: v2.2.0~14 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=b4174d5a793a209c8066231ba40c5727626d88fa;p=thirdparty%2Fhaproxy.git MINOR: log: Remove unused case statement during the log-format string parsing Since the commit cd0d2ed6e ("MEDIUM: log-format: make the LF parser aware of sample expressions' end"), the LF_STEXPR label in the last switch-case statement at the end of the for loop in the parse_logformat_string() function cannot be reached anymore. This patch should fix the issue #723. --- diff --git a/src/log.c b/src/log.c index e65b9ca995..937b675a73 100644 --- a/src/log.c +++ b/src/log.c @@ -717,10 +717,6 @@ int parse_logformat_string(const char *fmt, struct proxy *curproxy, struct list if (!parse_logformat_var(arg, arg_len, var, var_len, curproxy, list_format, &options, err)) goto fail; break; - case LF_STEXPR: - if (!add_sample_to_logformat_list(var, arg, arg_len, curproxy, list_format, options, cap, err, &sp)) - goto fail; - break; case LF_TEXT: case LF_SEPARATOR: if (!add_to_logformat_list(sp, str, pformat, list_format, err))