From 3aa6aa83d05249d7081a8c19a28ce9b9c4566da2 Mon Sep 17 00:00:00 2001 From: Stefan Boberg Date: Thu, 12 Mar 2026 17:02:01 +0100 Subject: Add --no-network option (#831) - Add `--no-network` CLI option which disables all TCP/HTTPS listeners, restricting zenserver to Unix domain socket communication only. - Also fixes asio upgrade breakage on main --- src/zenserver/proxy/zenproxyserver.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/zenserver/proxy/zenproxyserver.cpp') diff --git a/src/zenserver/proxy/zenproxyserver.cpp b/src/zenserver/proxy/zenproxyserver.cpp index 1fd9cd2c4..acfdad45f 100644 --- a/src/zenserver/proxy/zenproxyserver.cpp +++ b/src/zenserver/proxy/zenproxyserver.cpp @@ -302,7 +302,7 @@ ZenProxyServer::Initialize(const ZenProxyServerConfig& ServerConfig, ZenServerSt // Keep the io_context alive even when there is no pending work, so that // worker threads don't exit prematurely between async operations. - m_ProxyIoWorkGuard = std::make_unique(m_ProxyIoContext); + m_ProxyIoWorkGuard.emplace(m_ProxyIoContext.get_executor()); // Start proxy I/O worker threads. Use a modest thread count — proxy work is // I/O-bound so we don't need a thread per core, but having more than one @@ -404,7 +404,7 @@ ZenProxyServer::Cleanup() Service->Stop(); } - m_ProxyIoWorkGuard.reset(); + m_ProxyIoWorkGuard.reset(); // releases the work guard, allowing io_context to finish m_ProxyIoContext.stop(); for (auto& Thread : m_ProxyIoThreads) { -- cgit v1.2.3