From f7504639fafe7dc1dbcefa76d039bff0cd12bbe9 Mon Sep 17 00:00:00 2001 From: Piotr Przybylski Date: Sun, 25 Oct 2026 13:54:45 +0100 Subject: [PATCH] Control API: warn in single process mode only if API is enabled Previously, the "control API unavailable in single process mode" warning was logged on every start in single process mode, even without the "-l" option. --- src/core/nginx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/nginx.c b/src/core/nginx.c index 464911f60..a71d4cee7 100644 --- a/src/core/nginx.c +++ b/src/core/nginx.c @@ -368,7 +368,7 @@ main(int argc, char *const *argv) #endif #if (NGX_CONTROL_API) - if (ngx_process == NGX_PROCESS_SINGLE) { + if (ngx_control_api_enabled && ngx_process == NGX_PROCESS_SINGLE) { ngx_log_error(NGX_LOG_WARN, cycle->log, 0, "control API unavailable in single process mode"); -- 2.47.3