]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
qemuxml2argvtest: Remove unused separate parsing of arch
authorPeter Krempa <pkrempa@redhat.com>
Sat, 16 Dec 2023 07:58:55 +0000 (08:58 +0100)
committerPeter Krempa <pkrempa@redhat.com>
Wed, 17 Jan 2024 16:31:12 +0000 (17:31 +0100)
Prior to all tests being converted to "DO_TEST_CAPS*" invocation the
fake-caps tests required knowing the architecture, which was pre-parsed
in qemuxml2argvtest. This code was now removed, but the arch parser was
forgotten.

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

index 114943f22eb9c6b9546e5b1e705b132ebb98dc17..8b9cb1c01a9635c5175f85a2d43a1cff6a210d5e 100644 (file)
@@ -618,8 +618,6 @@ testCompareXMLToArgv(const void *data)
     qemuDomainObjPrivate *priv = NULL;
     g_autoptr(xmlDoc) xml = NULL;
     g_autoptr(xmlXPathContext) ctxt = NULL;
-    g_autofree char *archstr = NULL;
-    virArch arch = VIR_ARCH_NONE;
     g_autoptr(virIdentity) sysident = virIdentityGetSystem();
 
     /* mark test case as used */
@@ -675,12 +673,6 @@ testCompareXMLToArgv(const void *data)
                             "domain", &ctxt, NULL, false)))
         goto cleanup;
 
-    if ((archstr = virXPathString("string(./os/type[1]/@arch)", ctxt)))
-        arch = virArchFromString(archstr);
-
-    if (arch == VIR_ARCH_NONE)
-        arch = virArchFromHost();
-
     virFileCacheClear(driver.qemuCapsCache);
 
     if (qemuTestCapsCacheInsert(driver.qemuCapsCache, info->qemuCaps) < 0)