From 7798c38fd3259da27dd458c0eba597066bb882a1 Mon Sep 17 00:00:00 2001 From: Christopher Faulet Date: Wed, 22 Apr 2026 17:24:56 +0200 Subject: [PATCH] BUG/MINOR: mux-h1: Fix test to skip trailers from chunked messages The test to remove trailers from chunked messages was inverted and is thus ineffective. The flag for the requests was tested on client side and the flag for the response was tested on server side. It should be the opposite. This patch must be backported as far as 3.2. --- src/mux_h1.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mux_h1.c b/src/mux_h1.c index b05ddcc9a..527d3495f 100644 --- a/src/mux_h1.c +++ b/src/mux_h1.c @@ -3471,8 +3471,8 @@ static size_t h1_make_trailers(struct h1s *h1s, struct h1m *h1m, struct htx *htx goto nextblk; /* Skip the trailers because the corresponding conf option was set */ - if ((!(h1m->flags & H1_MF_RESP) && (h1c->px->options & PR_O_HTTP_DROP_RES_TRLS)) || - ((h1m->flags & H1_MF_RESP) && (h1c->px->options & PR_O_HTTP_DROP_REQ_TRLS))) + if ((!(h1m->flags & H1_MF_RESP) && (h1c->px->options & PR_O_HTTP_DROP_REQ_TRLS)) || + ((h1m->flags & H1_MF_RESP) && (h1c->px->options & PR_O_HTTP_DROP_RES_TRLS))) goto nextblk; n = htx_get_blk_name(htx, blk);