From 3bb424c837eca2d8041f9e000a268a6a2b582981 Mon Sep 17 00:00:00 2001 From: Yu Watanabe Date: Wed, 11 Oct 2023 22:58:49 +0900 Subject: [PATCH] core/execute: suppress logs if LogLevelMax= is specified Fixes #29532. --- src/core/execute.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/core/execute.c b/src/core/execute.c index 7cf6601ee7e..ffbe0832f4e 100644 --- a/src/core/execute.c +++ b/src/core/execute.c @@ -4040,6 +4040,8 @@ static int exec_child( log_forget_fds(); log_set_open_when_needed(true); log_settle_target(); + if (context->log_level_max >= 0) + log_set_max_level(context->log_level_max); /* In case anything used libc syslog(), close this here, too */ closelog(); -- 2.39.5