Since virLogParseOutputs is going to be stripped from 'output defining' logic,
replace all relevant occurrences with virLogSetOutputs to make the change
transparent to all original callers (daemons mostly).
---
daemon/libvirtd.c | 6 +++---
src/locking/lock_daemon.c | 6 +++---
src/logging/log_daemon.c | 6 +++---
src/util/virlog.c | 2 +-
4 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/daemon/libvirtd.c b/daemon/libvirtd.c
index cc5190f..d0019b0 100644
--- a/daemon/libvirtd.c
+++ b/daemon/libvirtd.c
@@ -693,7 +693,7 @@ daemonSetupLogging(struct daemonConfig *config,
virLogParseFilters(config->log_filters);
if (virLogGetNbOutputs() == 0)
- virLogParseOutputs(config->log_outputs);
+ virLogSetOutputs(config->log_outputs);
/*
* Command line override for --verbose
@@ -720,7 +720,7 @@ daemonSetupLogging(struct daemonConfig *config,
if (virAsprintf(&tmp, "%d:journald", priority) < 0)
goto error;
- virLogParseOutputs(tmp);
+ virLogSetOutputs(tmp);
VIR_FREE(tmp);
}
}
@@ -763,7 +763,7 @@ daemonSetupLogging(struct daemonConfig *config,
if (virAsprintf(&tmp, "%d:stderr", virLogGetDefaultPriority())
< 0)
goto error;
}
- virLogParseOutputs(tmp);
+ virLogSetOutputs(tmp);
VIR_FREE(tmp);
}
diff --git a/src/locking/lock_daemon.c b/src/locking/lock_daemon.c
index f889a34..8d760b2 100644
--- a/src/locking/lock_daemon.c
+++ b/src/locking/lock_daemon.c
@@ -479,7 +479,7 @@ virLockDaemonSetupLogging(virLockDaemonConfigPtr config,
virLogParseFilters(config->log_filters);
if (virLogGetNbOutputs() == 0)
- virLogParseOutputs(config->log_outputs);
+ virLogSetOutputs(config->log_outputs);
/*
* If no defined outputs, and either running
@@ -493,7 +493,7 @@ virLockDaemonSetupLogging(virLockDaemonConfigPtr config,
if (access("/run/systemd/journal/socket", W_OK) >= 0) {
if (virAsprintf(&tmp, "%d:journald",
virLogGetDefaultPriority()) < 0)
goto error;
- virLogParseOutputs(tmp);
+ virLogSetOutputs(tmp);
VIR_FREE(tmp);
}
}
@@ -537,7 +537,7 @@ virLockDaemonSetupLogging(virLockDaemonConfigPtr config,
if (virAsprintf(&tmp, "%d:stderr", virLogGetDefaultPriority())
< 0)
goto error;
}
- virLogParseOutputs(tmp);
+ virLogSetOutputs(tmp);
VIR_FREE(tmp);
}
diff --git a/src/logging/log_daemon.c b/src/logging/log_daemon.c
index 90f8427..f8a96e8 100644
--- a/src/logging/log_daemon.c
+++ b/src/logging/log_daemon.c
@@ -402,7 +402,7 @@ virLogDaemonSetupLogging(virLogDaemonConfigPtr config,
virLogParseFilters(config->log_filters);
if (virLogGetNbOutputs() == 0)
- virLogParseOutputs(config->log_outputs);
+ virLogSetOutputs(config->log_outputs);
/*
* If no defined outputs, and either running
@@ -416,7 +416,7 @@ virLogDaemonSetupLogging(virLogDaemonConfigPtr config,
if (access("/run/systemd/journal/socket", W_OK) >= 0) {
if (virAsprintf(&tmp, "%d:journald",
virLogGetDefaultPriority()) < 0)
goto error;
- virLogParseOutputs(tmp);
+ virLogSetOutputs(tmp);
VIR_FREE(tmp);
}
}
@@ -460,7 +460,7 @@ virLogDaemonSetupLogging(virLogDaemonConfigPtr config,
if (virAsprintf(&tmp, "%d:stderr", virLogGetDefaultPriority())
< 0)
goto error;
}
- virLogParseOutputs(tmp);
+ virLogSetOutputs(tmp);
VIR_FREE(tmp);
}
diff --git a/src/util/virlog.c b/src/util/virlog.c
index 2cd3773..538a5b8 100644
--- a/src/util/virlog.c
+++ b/src/util/virlog.c
@@ -1475,7 +1475,7 @@ virLogSetFromEnv(void)
virLogParseFilters(debugEnv);
debugEnv = virGetEnvAllowSUID("LIBVIRT_LOG_OUTPUTS");
if (debugEnv && *debugEnv)
- virLogParseOutputs(debugEnv);
+ virLogSetOutputs(debugEnv);
}
--
2.4.11