From 69673ff7c6a1d38c52b0cbbd4609dde7da4338ba Mon Sep 17 00:00:00 2001 From: "andrey.bychkov" Date: Mon, 10 Aug 2026 16:26:23 +0300 Subject: [PATCH] fix(curl_thread_pool): clean up clients_in_proc in destroy() destroy() aborted and deleted clients in the queue but did not delete clients that were currently being processed (clients_in_proc). If a thread was terminated while processing a client, that client object and its CURL handle were leaked. --- libs/http_client/curl_thread_pool_p.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/libs/http_client/curl_thread_pool_p.cpp b/libs/http_client/curl_thread_pool_p.cpp index d9b1bfc7..dc562508 100644 --- a/libs/http_client/curl_thread_pool_p.cpp +++ b/libs/http_client/curl_thread_pool_p.cpp @@ -92,5 +92,10 @@ void CurlThreadPool::destroy() { for (auto c: *cr) delete c; } + { + auto cr = clients_in_proc.getRef(); + for (auto c: *cr) + delete c; + } // piCout << "~CurlThreadPool ok"; }