From: William Lallemand Date: Thu, 17 Mar 2022 13:57:23 +0000 (+0100) Subject: BUG/MINOR: httpclient: process the response when received before the end of the request X-Git-Tag: v2.6-dev4~57 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=1eca8943218eb79bffb3b7dce194b154314795ba;p=thirdparty%2Fhaproxy.git BUG/MINOR: httpclient: process the response when received before the end of the request A server could reply a response with a shut before the end of the htx transfer, in this case the httpclient would leave before computing the received response. This patch fixes the issue by calling the "process_data" label instead of the "more" label which don't do the si_shut. Must be bacported in 2.5. --- diff --git a/src/http_client.c b/src/http_client.c index c449418ed0..39d7aa2ace 100644 --- a/src/http_client.c +++ b/src/http_client.c @@ -728,7 +728,7 @@ static void httpclient_applet_io_handler(struct appctx *appctx) appctx->st0 = HTTPCLIENT_S_RES_STLINE; } - goto more; /* we need to leave the IO handler once we wrote the request */ + goto process_data; /* we need to leave the IO handler once we wrote the request */ } break;