From: Christopher Faulet Date: Fri, 5 Apr 2019 08:11:38 +0000 (+0200) Subject: MINOR: filters/htx: Use stream flags instead of px mode to instanciate a filter X-Git-Tag: v2.0-dev3~294 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0f17a9b510124bbdd7d75f438118c8d6ad3f9fa1;p=thirdparty%2Fhaproxy.git MINOR: filters/htx: Use stream flags instead of px mode to instanciate a filter In the function flt_stream_add_filter(), if the HTX is enabled, before attaching a filter to a stream, we test if the filter can handle it or not. If not, the filter is ignored. Before the proxy mode was tested. Now we test if the stream is an HTX stream or not. --- diff --git a/src/filters.c b/src/filters.c index 1a7727669b..95ba7728bd 100644 --- a/src/filters.c +++ b/src/filters.c @@ -389,7 +389,7 @@ flt_stream_add_filter(struct stream *s, struct flt_conf *fconf, unsigned int fla { struct filter *f; - if ((strm_fe(s)->options2 & PR_O2_USE_HTX) && !(fconf->flags & FLT_CFG_FL_HTX)) + if (IS_HTX_STRM(s) && !(fconf->flags & FLT_CFG_FL_HTX)) return 0; f = pool_alloc(pool_head_filter);