From 0b29b76a526d4ce6da073a7afbbd406bb6ea0463 Mon Sep 17 00:00:00 2001 From: Christopher Faulet Date: Mon, 5 Jan 2026 11:12:00 +0100 Subject: [PATCH] BUG/MEDIUM: peers: Properly handle shutdown when trying to get a line When a shutdown was reported to a peer applet, the event was not properly handled if it failed to receive data. The function responsible to get data was exiting too early if the applet buffer was empty, without testing the sedesc status. Because of this issue, it was possible to have frozen peer applets. For instance, it happend on client timeout. With too many frozen applets, it was possible to reach the maxconn. This patch should fix the issue #3234. It must be backported to 3.3. --- src/peers.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/peers.c b/src/peers.c index cd68b04c4..1d5b0bfd1 100644 --- a/src/peers.c +++ b/src/peers.c @@ -1212,7 +1212,7 @@ static inline int peer_getline(struct appctx *appctx) int n = 0; TRACE_ENTER(PEERS_EV_SESS_IO|PEERS_EV_RX_MSG, appctx); - if (applet_get_inbuf(appctx) == NULL || !applet_input_data(appctx)) { + if (applet_get_inbuf(appctx) == NULL) { applet_need_more_data(appctx); goto out; }