From 20d0e6064cf81240dac3cccc89c2bd299cca210d Mon Sep 17 00:00:00 2001 From: wangmeiyang Date: Wed, 23 Nov 2022 17:25:58 +0800 Subject: [PATCH 06/23] util: set facility when opening syslog channel MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit We're currently passing '0' which leaves the syslog facility unset. Since we're passing an explicit facility for syslog when using journald, it makes sense to be explicit when using syslog directly too. cherry-pick from ab96031943d494010166875f399656a6c13aadf5 Signed-off-by: Daniel P. Berrangé Signed-off-by: Meiyang Wang Reviewed-by: Ján Tomko --- src/util/virlog.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/util/virlog.c b/src/util/virlog.c index e4944d1258..1b510389da 100644 --- a/src/util/virlog.c +++ b/src/util/virlog.c @@ -1411,7 +1411,7 @@ virLogDefineOutputs(virLogOutputPtr *outputs, size_t noutputs) tmp = g_strdup(outputs[id]->name); VIR_FREE(current_ident); current_ident = tmp; - openlog(current_ident, 0, 0); + openlog(current_ident, 0, LOG_DAEMON); } #endif /* HAVE_SYSLOG_H */ -- 2.27.0