]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
qemuxml2xmltest: testInfoSetPaths: Remove return value
authorPeter Krempa <pkrempa@redhat.com>
Fri, 26 Mar 2021 17:53:32 +0000 (18:53 +0100)
committerPeter Krempa <pkrempa@redhat.com>
Mon, 12 Apr 2021 14:09:41 +0000 (16:09 +0200)
The function doesn't fail. Remove the return value and checks.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
tests/qemuxml2xmltest.c

index 70a4a57df1c44efcb1cc53f496a4f7e674f8bb62..03cb40512373fe9b98387c1c305489df8c37dd38 100644 (file)
@@ -50,7 +50,7 @@ testXML2XMLInactive(const void *opaque)
 }
 
 
-static int
+static void
 testInfoSetPaths(struct testQemuInfo *info,
                  const char *suffix,
                  int when)
@@ -71,8 +71,6 @@ testInfoSetPaths(struct testQemuInfo *info,
         info->outfile = g_strdup_printf("%s/qemuxml2xmloutdata/%s%s.xml",
                                         abs_srcdir, info->name, suffix);
     }
-
-    return 0;
 }
 
 
@@ -140,20 +138,14 @@ mymain(void)
         } \
  \
         if (when & WHEN_INACTIVE) { \
-            if (testInfoSetPaths(&info, suffix, WHEN_INACTIVE) < 0) { \
-                VIR_TEST_DEBUG("Failed to generate inactive paths for '%s'", _name); \
-                return -1; \
-            } \
+            testInfoSetPaths(&info, suffix, WHEN_INACTIVE); \
             if (virTestRun("QEMU XML-2-XML-inactive " _name, \
                             testXML2XMLInactive, &info) < 0) \
                 ret = -1; \
         } \
  \
         if (when & WHEN_ACTIVE) { \
-            if (testInfoSetPaths(&info, suffix, WHEN_ACTIVE) < 0) { \
-                VIR_TEST_DEBUG("Failed to generate active paths for '%s'", _name); \
-                return -1; \
-            } \
+            testInfoSetPaths(&info, suffix, WHEN_ACTIVE); \
             if (virTestRun("QEMU XML-2-XML-active " _name, \
                             testXML2XMLActive, &info) < 0) \
                 ret = -1; \