[PATCH 12/38] virlog: Rename virLogAddOutputTo to virLogNewOutput

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is merely a cosmetic change to clearly state that we won't be adding a
new output to the existing global set of outputs, instead we're always creating
a completely new output that needs to be later placed into a list.
---
 src/util/virlog.c | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/src/util/virlog.c b/src/util/virlog.c
index 60573a9..387e08a 100644
--- a/src/util/virlog.c
+++ b/src/util/virlog.c
@@ -714,7 +714,7 @@ virLogCloseFd(void *data)
 
 
 static int
-virLogAddOutputToStderr(virLogPriority priority)
+virLogNewOutputToStderr(virLogPriority priority)
 {
     if (virLogDefineOutput(virLogOutputToFd, NULL, (void *)2L, priority,
                            VIR_LOG_TO_STDERR, NULL, 0) < 0)
@@ -724,7 +724,7 @@ virLogAddOutputToStderr(virLogPriority priority)
 
 
 static int
-virLogAddOutputToFile(virLogPriority priority,
+virLogNewOutputToFile(virLogPriority priority,
                       const char *file)
 {
     int fd;
@@ -808,7 +808,7 @@ virLogCloseSyslog(void *data ATTRIBUTE_UNUSED)
 
 
 static int
-virLogAddOutputToSyslog(virLogPriority priority,
+virLogNewOutputToSyslog(virLogPriority priority,
                         const char *ident)
 {
     /*
@@ -1031,7 +1031,7 @@ static void virLogCloseJournald(void *data ATTRIBUTE_UNUSED)
 }
 
 
-static int virLogAddOutputToJournald(int priority)
+static int virLogNewOutputToJournald(int priority)
 {
     if ((journalfd = socket(AF_UNIX, SOCK_DGRAM, 0)) < 0)
         return -1;
@@ -1119,22 +1119,22 @@ virLogParseOutput(const char *src)
 
     switch ((virLogDestination) dest) {
     case VIR_LOG_TO_STDERR:
-        ret = virLogAddOutputToStderr(prio);
+        ret = virLogNewOutputToStderr(prio);
         break;
     case VIR_LOG_TO_SYSLOG:
 #if HAVE_SYSLOG_H
-        ret = virLogAddOutputToSyslog(prio, tokens[2]);
+        ret = virLogNewOutputToSyslog(prio, tokens[2]);
 #endif
         break;
     case VIR_LOG_TO_FILE:
         if (virFileAbsPath(tokens[2], &abspath) < 0)
             goto cleanup;
-        ret = virLogAddOutputToFile(prio, abspath);
+        ret = virLogNewOutputToFile(prio, abspath);
         VIR_FREE(abspath);
         break;
     case VIR_LOG_TO_JOURNALD:
 #if USE_JOURNALD
-        ret = virLogAddOutputToJournald(prio);
+        ret = virLogNewOutputToJournald(prio);
 #endif
         break;
     case VIR_LOG_TO_OUTPUT_LAST:
-- 
2.4.3

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]