[PATCH 09/33] lxc_process: Remove OOM handling from logging setup

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

 



'virLogGetFilters' doesn't return failure and 'virLogGetOutputs' reports
it's own errors.

Signed-off-by: Peter Krempa <pkrempa@xxxxxxxxxx>
---
 src/lxc/lxc_process.c | 9 +--------
 1 file changed, 1 insertion(+), 8 deletions(-)

diff --git a/src/lxc/lxc_process.c b/src/lxc/lxc_process.c
index cbc04a3dcd..679709605e 100644
--- a/src/lxc/lxc_process.c
+++ b/src/lxc/lxc_process.c
@@ -960,21 +960,14 @@ virLXCProcessBuildControllerCmd(virLXCDriverPtr driver,

     if (virLogGetNbFilters() > 0) {
         filterstr = virLogGetFilters();
-        if (!filterstr) {
-            virReportOOMError();
-            goto error;
-        }

         virCommandAddEnvPair(cmd, "LIBVIRT_LOG_FILTERS", filterstr);
     }

     if (cfg->log_libvirtd) {
         if (virLogGetNbOutputs() > 0) {
-            outputstr = virLogGetOutputs();
-            if (!outputstr) {
-                virReportOOMError();
+            if (!(outputstr = virLogGetOutputs()))
                 goto error;
-            }

             virCommandAddEnvPair(cmd, "LIBVIRT_LOG_OUTPUTS", outputstr);
         }
-- 
2.29.2




[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]

  Powered by Linux