From: Christopher Faulet Date: Wed, 16 Sep 2026 07:19:46 +0000 (+0200) Subject: BUG/MEDIUM: http-client/cli: Notify the http-client when the response is consumed X-Git-Tag: v3.5-dev8~182 X-Git-Url: https://git.kaiwu.me/?a=commitdiff_plain;h=cf862475cda075df14d1853b405fb30eb5e1f5b9;p=haproxy.git BUG/MEDIUM: http-client/cli: Notify the http-client when the response is consumed In HTX mode, the "httpclient" CLI command does not use httpclient_res_xfer() to consume the response. It dumps the HTX message stored in the http-client response buffer and resets it by hand. Thus, since commit b24260ec9 ("BUG/MEDIUM: http-client: Only consume input buffer when hc one is empty"), the applet stops to consume data and is never woken up again. The command is stuck just after the response headers, till the server timeout expiration. httpclient_res_consumed() is now called when the response buffer is reset. This patch depends on : * MINOR: http-client: Add a function to notify some data were consumed It must be backported as far as 3.3 with commit b24260ec9. --- diff --git a/src/httpclient_cli.c b/src/httpclient_cli.c index c7b3166f5..7de4c8911 100644 --- a/src/httpclient_cli.c +++ b/src/httpclient_cli.c @@ -230,6 +230,7 @@ static int hc_cli_io_handler(struct appctx *appctx) goto more; htx_reset(hc_htx); htx_to_buf(hc_htx, &hc->res.buf); + httpclient_res_consumed(hc); }