We should not report LAST data in log if the response is in TUNNEL mode on
client close/timeout because there is no way to be sure it is the last
data. It means, it can only be reported in DONE, CLOSING or CLOSE states.
No backport needed.
/* We are still processing the response headers */
s->flags |= SF_FINST_H;
}
- // (res >= done) & (res->flags & shutw)
- else if (s->txn->rsp.msg_state >= HTTP_MSG_DONE &&
+ // (res == (done|closing|closed)) & (res->flags & shutw)
+ else if (s->txn->rsp.msg_state >= HTTP_MSG_DONE && s->txn->rsp.msg_state < HTTP_MSG_TUNNEL &&
(s->flags & (SF_ERR_CLITO|SF_ERR_CLICL))) {
/* A client error was reported and we are
* transmitting the last block of data