From: Christopher Faulet Date: Fri, 6 Mar 2020 14:10:46 +0000 (+0100) Subject: BUG/MINOR: rules: Preserve FLT_END analyzers on silent-drop action X-Git-Tag: v2.1.4~40 X-Git-Url: http://git.haproxy.org/?a=commitdiff_plain;h=e15005b1f975a82126f29d912cd9e5419448c845;p=haproxy-2.1.git BUG/MINOR: rules: Preserve FLT_END analyzers on silent-drop action When at least a filter is attached to a stream, FLT_END analyzers must be preserved on request and response channels. This patch should be backported as far as 1.7. (cherry picked from commit 177f480f2c5b6a73b148a7069a71ddbff3e9f6a6) Signed-off-by: Willy Tarreau --- diff --git a/src/proto_tcp.c b/src/proto_tcp.c index d23bf97..9211170 100644 --- a/src/proto_tcp.c +++ b/src/proto_tcp.c @@ -1355,9 +1355,8 @@ static enum act_return tcp_exec_action_silent_drop(struct act_rule *rule, struct if (strm) { channel_abort(&strm->req); channel_abort(&strm->res); - strm->req.analysers = 0; - strm->res.analysers = 0; - _HA_ATOMIC_ADD(&strm->be->be_counters.denied_req, 1); + strm->req.analysers &= AN_REQ_FLT_END; + strm->res.analysers &= AN_RES_FLT_END; if (!(strm->flags & SF_ERR_MASK)) strm->flags |= SF_ERR_PRXCOND; if (!(strm->flags & SF_FINST_MASK))