mirror of
https://git.haproxy.org/git/haproxy.git/
synced 2025-09-21 13:51:26 +02:00
BUG/MAJOR: http: fix regression introduced by commit d655ffe
Sander Klein reported that since last snapshot, some downloads would hang from nginx but succeed from apache. The culprit was not too hard to find given the low number of recent changes affecting the data path. Commit d655ffe slightly reorganized the HTTP state machine and introduced this regression. The reason is that we must never jump into the MSG_DONE case without first flushing remaining data because this is not done anymore afterwards. This part is scheduled for being reorganized since it's totally ugly especially since we added compression, and this regression is an illustration of its readability. The issue is entirely dependant on the server close sequence, which explains why it was reproducible only with nginx here.
This commit is contained in:
parent
ffb6f08bab
commit
2d43e18b69
@ -5936,7 +5936,10 @@ int http_response_forward_body(struct session *s, struct channel *res, int an_bi
|
||||
channel_forward(res, msg->next);
|
||||
msg->next = 0;
|
||||
}
|
||||
/* we're in HTTP_MSG_DONE now, fall through */
|
||||
/* we're in HTTP_MSG_DONE now, but we might still have
|
||||
* some data pending, so let's loop over once.
|
||||
*/
|
||||
break;
|
||||
|
||||
default:
|
||||
/* other states, DONE...TUNNEL */
|
||||
|
Loading…
x
Reference in New Issue
Block a user