From: Willy Tarreau Date: Tue, 14 May 2019 09:31:00 +0000 (+0200) Subject: CLEANUP: mux-h2: don't test for impossible CS_FL_REOS conditions X-Git-Tag: v2.0-dev3~10 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f8fe3d63f0135fdd211034b97c9bffa66948b583;p=thirdparty%2Fhaproxy.git CLEANUP: mux-h2: don't test for impossible CS_FL_REOS conditions This flag is currently set when an incoming close was received, which results in the stream being in either H2_SS_HREM, H2_SS_CLOSED, or H2_SS_ERROR states, so let's remove the test for the OPEN and HLOC cases. --- diff --git a/src/mux_h2.c b/src/mux_h2.c index bf6c53de45..9455ff952e 100644 --- a/src/mux_h2.c +++ b/src/mux_h2.c @@ -2078,9 +2078,9 @@ static struct h2s *h2c_bck_handle_headers(struct h2c *h2c, struct h2s *h2s) if (h2s->cs && h2s->cs->flags & CS_FL_ERROR && h2s->st < H2_SS_ERROR) h2s->st = H2_SS_ERROR; - else if (h2s->cs && (h2s->cs->flags & (CS_FL_EOI|CS_FL_REOS)) && h2s->st == H2_SS_OPEN) + else if (h2s->cs && (h2s->cs->flags & CS_FL_EOI) && h2s->st == H2_SS_OPEN) h2s->st = H2_SS_HREM; - else if ((!h2s->cs || h2s->cs->flags & (CS_FL_EOI|CS_FL_REOS)) && h2s->st == H2_SS_HLOC) + else if ((!h2s->cs || h2s->cs->flags & CS_FL_EOI) && h2s->st == H2_SS_HLOC) h2s_close(h2s); return h2s;