BUG/MEDIUM: mux-h1: Be sure to have a conn_stream to set CS_FL_REOS in h1_recv

In the commit 6a2d33481 ("BUG/MEDIUM: h1: Set CS_FL_REOS if we had a read0."),
We set the flag CS_FL_REOS on the conn_stream when a read0 is detected. But we
must be sure to have a conn_stream first.
This commit is contained in:
Christopher Faulet 2018-12-07 09:42:49 +01:00 committed by Willy Tarreau
parent 6a2d334812
commit e6b39942d1

View File

@ -1587,7 +1587,7 @@ static int h1_recv(struct h1c *h1c)
h1s->recv_wait = NULL;
}
if (conn_xprt_read0_pending(conn))
if (conn_xprt_read0_pending(conn) && h1s && h1s->cs)
h1s->cs->flags |= CS_FL_REOS;
if (!b_data(&h1c->ibuf))
h1_release_buf(h1c, &h1c->ibuf);