From: Aurelien DARRAGON Date: Mon, 26 Jun 2023 12:22:12 +0000 (+0200) Subject: BUG/MINOR: ring: maxlen warning reported as alert X-Git-Tag: v2.9-dev2~73 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=c103379847d199752ff0206aabb34cc7c0455c4c;p=thirdparty%2Fhaproxy.git BUG/MINOR: ring: maxlen warning reported as alert When maxlen parameter exceeds sink size, a warning is generated and maxlen is enforced to sink size. But the err_code is incorrectly set to ERR_ALERT Indeed, being a "warning", ERR_WARN should be used here. This may be backported as far as 2.2 --- diff --git a/src/sink.c b/src/sink.c index e114909615..136945eb07 100644 --- a/src/sink.c +++ b/src/sink.c @@ -1191,7 +1191,7 @@ int cfg_post_parse_ring() ha_warning("ring '%s' event max length '%u' exceeds size, forced to size '%lu'.\n", cfg_sink->name, cfg_sink->maxlen, (unsigned long)b_size(&cfg_sink->ctx.ring->buf)); cfg_sink->maxlen = b_size(&cfg_sink->ctx.ring->buf); - err_code |= ERR_ALERT; + err_code |= ERR_WARN; } /* prepare forward server descriptors */