When HTTP_MSGF_ERROR is set on a channel (the request or the response), the
request must be truncated, not the response.
if (unlikely(txn->req.msg_state == HTTP_MSG_ERROR ||
txn->rsp.msg_state == HTTP_MSG_ERROR)) {
- channel_truncate(chn);
+ channel_truncate(&s->req);
channel_abort(&s->req);
goto end;
}
if (txn->rsp.msg_state == HTTP_MSG_CLOSED) {
http_msg_closed:
/* drop any pending data */
- channel_truncate(chn);
+ channel_truncate(&s->req);
channel_abort(&s->req);
goto end;
}