BUG/MEDIUM: mux-h2: make sure to report synchronous errors after EOS

If EOS has already been reported on the conn_stream, there won't be
any read anymore to turn ERR_PENDING into ERROR, so we have to do
report it directly.

No backport is needed.
This commit is contained in:
Willy Tarreau 2018-12-18 16:39:21 +01:00
parent d5e3c71208
commit 7ecb6f10a4

View File

@ -1739,7 +1739,11 @@ static int h2c_handle_rst_stream(struct h2c *h2c, struct h2s *h2s)
h2s_close(h2s);
if (h2s->cs) {
h2s->cs->flags |= CS_FL_REOS | CS_FL_ERR_PENDING;
if (h2s->cs->flags & CS_FL_EOS)
h2s->cs->flags |= CS_FL_ERROR;
else
h2s->cs->flags |= CS_FL_REOS | CS_FL_ERR_PENDING;
if (h2s->recv_wait) {
struct wait_event *sw = h2s->recv_wait;