BUG/MINOR: filters: Set right FLT_END analyser depending on channel

A bug was introduced by the commit 26eb5ea35 ("BUG/MINOR: filters: Always
set FLT_END analyser when CF_FLT_ANALYZE flag is set"). Depending on the
channel evaluated, the rigth FLT_END analyser must be set. AN_REQ_FLT_END
for the request channel and AN_RES_FLT_END for the response one.

Ths patch must be backported everywhere the above commit was backported.

(cherry picked from commit 949b6ca961904c7414fc22204461f9882afff4ea)
Signed-off-by: Christopher Faulet <cfaulet@haproxy.com>
diff --git a/src/filters.c b/src/filters.c
index 7640464..136a3e8 100644
--- a/src/filters.c
+++ b/src/filters.c
@@ -537,7 +537,7 @@
 	}
 	if (be->be_req_ana & AN_REQ_FLT_START_BE) {
 		s->req.flags |= CF_FLT_ANALYZE;
-		s->req.analysers |= AN_RES_FLT_END;
+		s->req.analysers |= AN_REQ_FLT_END;
 	}
 	if ((strm_fe(s)->fe_rsp_ana | be->be_rsp_ana) & (AN_RES_FLT_START_FE|AN_RES_FLT_START_BE)) {
 		s->res.flags |= CF_FLT_ANALYZE;
@@ -712,7 +712,7 @@
 
 	/* Set flag on channel to tell that the channel is filtered */
 	chn->flags |= CF_FLT_ANALYZE;
-	chn->analysers |= AN_RES_FLT_END;
+	chn->analysers |= ((chn->flags & CF_ISRESP) ? AN_RES_FLT_END : AN_REQ_FLT_END);
 
 	RESUME_FILTER_LOOP(s, chn) {
 		if (!(chn->flags & CF_ISRESP)) {