diff --git a/src/mux_h2.c b/src/mux_h2.c index 2129f7f07..6ecec4d62 100644 --- a/src/mux_h2.c +++ b/src/mux_h2.c @@ -4438,8 +4438,10 @@ static size_t h2s_htx_frt_make_resp_headers(struct h2s *h2s, struct htx *htx) } /* get the start line, we do have one */ - sl = htx_get_stline(htx); - ALREADY_CHECKED(sl); + blk = htx_get_head_blk(htx); + BUG_ON(htx_get_blk_type(blk) != HTX_BLK_RES_SL); + ALREADY_CHECKED(blk); + sl = htx_get_blk_ptr(htx, blk); h2s->status = sl->info.res.status; if (h2s->status < 100 || h2s->status > 999) goto fail; @@ -4645,8 +4647,10 @@ static size_t h2s_htx_bck_make_req_headers(struct h2s *h2s, struct htx *htx) } /* get the start line, we do have one */ - sl = htx_get_stline(htx); - ALREADY_CHECKED(sl); + blk = htx_get_head_blk(htx); + BUG_ON(htx_get_blk_type(blk) != HTX_BLK_REQ_SL); + ALREADY_CHECKED(blk); + sl = htx_get_blk_ptr(htx, blk); meth = htx_sl_req_meth(sl); path = htx_sl_req_uri(sl);