mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-18 10:35:20 +00:00
lib: Don't check for virCapabilitiesAddGuest() retval
The virCapabilitiesAddGuest() function can't fail. It aborts on OOM. Therefore, there's no need to check for its return value. Signed-off-by: Michal Privoznik <mprivozn@redhat.com> Reviewed-by: Ján Tomko <jtomko@redhat.com>
This commit is contained in:
parent
42cc2f9396
commit
c18d9e23fa
@ -50,11 +50,9 @@ virBhyveCapsBuild(void)
|
||||
false, false)) == NULL)
|
||||
return NULL;
|
||||
|
||||
if ((guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM,
|
||||
VIR_ARCH_X86_64,
|
||||
"bhyve",
|
||||
NULL, 0, NULL)) == NULL)
|
||||
goto error;
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM,
|
||||
VIR_ARCH_X86_64, "bhyve",
|
||||
NULL, 0, NULL);
|
||||
|
||||
if (virCapabilitiesAddGuestDomain(guest, VIR_DOMAIN_VIRT_BHYVE,
|
||||
NULL, NULL, 0, NULL) == NULL)
|
||||
|
@ -65,14 +65,8 @@ virCaps *virCHDriverCapsInit(void)
|
||||
if (virCapabilitiesInitCaches(caps) < 0)
|
||||
goto cleanup;
|
||||
|
||||
if ((guest = virCapabilitiesAddGuest(caps,
|
||||
VIR_DOMAIN_OSTYPE_HVM,
|
||||
caps->host.arch,
|
||||
NULL,
|
||||
NULL,
|
||||
0,
|
||||
NULL)) == NULL)
|
||||
goto cleanup;
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM,
|
||||
caps->host.arch, NULL, NULL, 0, NULL);
|
||||
|
||||
if (virCapabilitiesAddGuestDomain(guest,
|
||||
VIR_DOMAIN_VIRT_KVM,
|
||||
|
@ -567,9 +567,6 @@ esxCapsInit(esxPrivate *priv)
|
||||
NULL, NULL, 0,
|
||||
NULL);
|
||||
|
||||
if (!guest)
|
||||
goto failure;
|
||||
|
||||
if (!virCapabilitiesAddGuestDomain(guest, VIR_DOMAIN_VIRT_VMWARE, NULL, NULL, 0, NULL))
|
||||
goto failure;
|
||||
|
||||
@ -580,9 +577,6 @@ esxCapsInit(esxPrivate *priv)
|
||||
NULL, NULL,
|
||||
0, NULL);
|
||||
|
||||
if (!guest)
|
||||
goto failure;
|
||||
|
||||
if (!virCapabilitiesAddGuestDomain(guest, VIR_DOMAIN_VIRT_VMWARE, NULL, NULL, 0, NULL))
|
||||
goto failure;
|
||||
}
|
||||
|
@ -276,8 +276,6 @@ hypervCapsInit(hypervPrivate *priv)
|
||||
/* i686 caps */
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM, VIR_ARCH_I686,
|
||||
NULL, NULL, 0, NULL);
|
||||
if (!guest)
|
||||
goto error;
|
||||
|
||||
if (!virCapabilitiesAddGuestDomain(guest, VIR_DOMAIN_VIRT_HYPERV, NULL, NULL, 0, NULL))
|
||||
goto error;
|
||||
@ -285,8 +283,6 @@ hypervCapsInit(hypervPrivate *priv)
|
||||
/* x86_64 caps */
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM, VIR_ARCH_X86_64,
|
||||
NULL, NULL, 0, NULL);
|
||||
if (!guest)
|
||||
goto error;
|
||||
|
||||
if (!virCapabilitiesAddGuestDomain(guest, VIR_DOMAIN_VIRT_HYPERV, NULL, NULL, 0, NULL))
|
||||
goto error;
|
||||
|
@ -473,20 +473,17 @@ libxlCapsInitGuests(libxl_ctx *ctx, virCaps *caps)
|
||||
if ((machines = virCapabilitiesAllocMachines(xen_machines, 1)) == NULL)
|
||||
return -1;
|
||||
|
||||
if ((guest = virCapabilitiesAddGuest(caps,
|
||||
guest_archs[i].hvm ? VIR_DOMAIN_OSTYPE_HVM :
|
||||
(guest_archs[i].pvh ? VIR_DOMAIN_OSTYPE_XENPVH :
|
||||
VIR_DOMAIN_OSTYPE_XEN),
|
||||
guest_archs[i].arch,
|
||||
LIBXL_EXECBIN_DIR "/qemu-system-i386",
|
||||
(guest_archs[i].hvm ?
|
||||
LIBXL_FIRMWARE_DIR "/hvmloader" :
|
||||
NULL),
|
||||
1,
|
||||
machines)) == NULL) {
|
||||
virCapabilitiesFreeMachines(machines, 1);
|
||||
return -1;
|
||||
}
|
||||
guest = virCapabilitiesAddGuest(caps,
|
||||
guest_archs[i].hvm ? VIR_DOMAIN_OSTYPE_HVM :
|
||||
(guest_archs[i].pvh ? VIR_DOMAIN_OSTYPE_XENPVH :
|
||||
VIR_DOMAIN_OSTYPE_XEN),
|
||||
guest_archs[i].arch,
|
||||
LIBXL_EXECBIN_DIR "/qemu-system-i386",
|
||||
(guest_archs[i].hvm ?
|
||||
LIBXL_FIRMWARE_DIR "/hvmloader" :
|
||||
NULL),
|
||||
1,
|
||||
machines);
|
||||
machines = NULL;
|
||||
|
||||
if (virCapabilitiesAddGuestDomain(guest,
|
||||
|
@ -97,14 +97,8 @@ virCaps *virLXCDriverCapsInit(virLXCDriver *driver)
|
||||
LIBEXECDIR)))
|
||||
goto error;
|
||||
|
||||
if ((guest = virCapabilitiesAddGuest(caps,
|
||||
VIR_DOMAIN_OSTYPE_EXE,
|
||||
caps->host.arch,
|
||||
lxc_path,
|
||||
NULL,
|
||||
0,
|
||||
NULL)) == NULL)
|
||||
goto error;
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_EXE,
|
||||
caps->host.arch, lxc_path, NULL, 0, NULL);
|
||||
|
||||
if (virCapabilitiesAddGuestDomain(guest,
|
||||
VIR_DOMAIN_VIRT_LXC,
|
||||
@ -116,14 +110,8 @@ virCaps *virLXCDriverCapsInit(virLXCDriver *driver)
|
||||
|
||||
/* On 64-bit hosts, we can use personality() to request a 32bit process */
|
||||
if ((altArch = lxcContainerGetAlt32bitArch(caps->host.arch)) != VIR_ARCH_NONE) {
|
||||
if ((guest = virCapabilitiesAddGuest(caps,
|
||||
VIR_DOMAIN_OSTYPE_EXE,
|
||||
altArch,
|
||||
lxc_path,
|
||||
NULL,
|
||||
0,
|
||||
NULL)) == NULL)
|
||||
goto error;
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_EXE,
|
||||
altArch, lxc_path, NULL, 0, NULL);
|
||||
|
||||
if (virCapabilitiesAddGuestDomain(guest,
|
||||
VIR_DOMAIN_VIRT_LXC,
|
||||
|
@ -156,14 +156,8 @@ virCaps *openvzCapsInit(void)
|
||||
if (virCapabilitiesInitCaches(caps) < 0)
|
||||
return NULL;
|
||||
|
||||
if ((guest = virCapabilitiesAddGuest(caps,
|
||||
VIR_DOMAIN_OSTYPE_EXE,
|
||||
caps->host.arch,
|
||||
NULL,
|
||||
NULL,
|
||||
0,
|
||||
NULL)) == NULL)
|
||||
return NULL;
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_EXE,
|
||||
caps->host.arch, NULL, NULL, 0, NULL);
|
||||
|
||||
if (virCapabilitiesAddGuestDomain(guest,
|
||||
VIR_DOMAIN_VIRT_OPENVZ,
|
||||
|
@ -1050,14 +1050,9 @@ virQEMUCapsInitGuestFromBinary(virCaps *caps,
|
||||
|
||||
/* We register kvm as the base emulator too, since we can
|
||||
* just give -no-kvm to disable acceleration if required */
|
||||
if ((guest = virCapabilitiesAddGuest(caps,
|
||||
VIR_DOMAIN_OSTYPE_HVM,
|
||||
guestarch,
|
||||
binary,
|
||||
NULL,
|
||||
nmachines,
|
||||
machines)) == NULL)
|
||||
goto cleanup;
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM,
|
||||
guestarch, binary,
|
||||
NULL, nmachines, machines);
|
||||
|
||||
machines = NULL;
|
||||
nmachines = 0;
|
||||
|
@ -642,16 +642,8 @@ get_definition(vahControl * ctl, const char *xmlStr)
|
||||
return -1;
|
||||
}
|
||||
|
||||
if ((guest = virCapabilitiesAddGuest(ctl->caps,
|
||||
ostype,
|
||||
ctl->arch,
|
||||
NULL,
|
||||
NULL,
|
||||
0,
|
||||
NULL)) == NULL) {
|
||||
vah_error(ctl, 0, _("could not allocate memory"));
|
||||
return -1;
|
||||
}
|
||||
guest = virCapabilitiesAddGuest(ctl->caps, ostype, ctl->arch,
|
||||
NULL, NULL, 0, NULL);
|
||||
|
||||
if ((virtType = virDomainVirtTypeFromString(ctl->virtType)) < 0) {
|
||||
vah_error(ctl, 0, _("unknown virtualization type"));
|
||||
|
@ -345,14 +345,8 @@ testBuildCapabilities(virConnectPtr conn)
|
||||
}
|
||||
|
||||
for (i = 0; i < G_N_ELEMENTS(guest_types); i++) {
|
||||
if ((guest = virCapabilitiesAddGuest(caps,
|
||||
guest_types[i],
|
||||
VIR_ARCH_I686,
|
||||
TEST_EMULATOR,
|
||||
NULL,
|
||||
0,
|
||||
NULL)) == NULL)
|
||||
goto error;
|
||||
guest = virCapabilitiesAddGuest(caps, guest_types[i], VIR_ARCH_I686,
|
||||
TEST_EMULATOR, NULL, 0, NULL);
|
||||
|
||||
if (virCapabilitiesAddGuestDomain(guest,
|
||||
VIR_DOMAIN_VIRT_TEST,
|
||||
|
@ -100,13 +100,8 @@ vboxCapsInit(void)
|
||||
if (virCapabilitiesInitCaches(caps) < 0)
|
||||
return NULL;
|
||||
|
||||
if ((guest = virCapabilitiesAddGuest(caps,
|
||||
VIR_DOMAIN_OSTYPE_HVM,
|
||||
caps->host.arch,
|
||||
NULL,
|
||||
NULL,
|
||||
0,
|
||||
NULL)) == NULL)
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM,
|
||||
caps->host.arch, NULL, NULL, 0, NULL);
|
||||
return NULL;
|
||||
|
||||
if (virCapabilitiesAddGuestDomain(guest,
|
||||
|
@ -78,11 +78,8 @@ vmwareCapsInit(void)
|
||||
VIR_WARN("Failed to get host CPU cache info");
|
||||
|
||||
/* i686 guests are always supported */
|
||||
if ((guest = virCapabilitiesAddGuest(caps,
|
||||
VIR_DOMAIN_OSTYPE_HVM,
|
||||
VIR_ARCH_I686,
|
||||
NULL, NULL, 0, NULL)) == NULL)
|
||||
goto error;
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM,
|
||||
VIR_ARCH_I686, NULL, NULL, 0, NULL);
|
||||
|
||||
if (virCapabilitiesAddGuestDomain(guest,
|
||||
VIR_DOMAIN_VIRT_VMWARE,
|
||||
@ -103,11 +100,8 @@ vmwareCapsInit(void)
|
||||
(virCPUCheckFeature(caps->host.cpu->arch, caps->host.cpu, "vmx") ||
|
||||
virCPUCheckFeature(caps->host.cpu->arch, caps->host.cpu, "svm")))) {
|
||||
|
||||
if ((guest = virCapabilitiesAddGuest(caps,
|
||||
VIR_DOMAIN_OSTYPE_HVM,
|
||||
VIR_ARCH_X86_64,
|
||||
NULL, NULL, 0, NULL)) == NULL)
|
||||
goto error;
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM,
|
||||
VIR_ARCH_X86_64, NULL, NULL, 0, NULL);
|
||||
|
||||
if (virCapabilitiesAddGuestDomain(guest,
|
||||
VIR_DOMAIN_VIRT_VMWARE,
|
||||
|
@ -83,8 +83,8 @@ vzCapsAddGuestDomain(virCaps *caps,
|
||||
{
|
||||
virCapsGuest *guest;
|
||||
|
||||
if ((guest = virCapabilitiesAddGuest(caps, ostype, arch, emulator,
|
||||
NULL, 0, NULL)) == NULL)
|
||||
guest = virCapabilitiesAddGuest(caps, ostype, arch,
|
||||
emulator, NULL, 0, NULL);
|
||||
return -1;
|
||||
|
||||
|
||||
|
@ -903,10 +903,8 @@ virTestGenericCapsInit(void)
|
||||
false, false)) == NULL)
|
||||
return NULL;
|
||||
|
||||
if ((guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM, VIR_ARCH_I686,
|
||||
"/usr/bin/acme-virt", NULL,
|
||||
0, NULL)) == NULL)
|
||||
return NULL;
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM, VIR_ARCH_I686,
|
||||
"/usr/bin/acme-virt", NULL, 0, NULL);
|
||||
|
||||
if (!virCapabilitiesAddGuestDomain(guest, VIR_DOMAIN_VIRT_TEST, NULL, NULL, 0, NULL))
|
||||
return NULL;
|
||||
@ -917,10 +915,8 @@ virTestGenericCapsInit(void)
|
||||
NULL, NULL, 0, NULL))
|
||||
return NULL;
|
||||
|
||||
if ((guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM, VIR_ARCH_X86_64,
|
||||
"/usr/bin/acme-virt", NULL,
|
||||
0, NULL)) == NULL)
|
||||
return NULL;
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM, VIR_ARCH_X86_64,
|
||||
"/usr/bin/acme-virt", NULL, 0, NULL);
|
||||
|
||||
if (!virCapabilitiesAddGuestDomain(guest, VIR_DOMAIN_VIRT_TEST, NULL, NULL, 0, NULL))
|
||||
return NULL;
|
||||
|
@ -18,21 +18,19 @@ testLXCCapsInit(void)
|
||||
false, false)) == NULL)
|
||||
return NULL;
|
||||
|
||||
if ((guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_EXE,
|
||||
VIR_ARCH_I686,
|
||||
"/usr/libexec/libvirt_lxc", NULL,
|
||||
0, NULL)) == NULL)
|
||||
goto error;
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_EXE,
|
||||
VIR_ARCH_I686,
|
||||
"/usr/libexec/libvirt_lxc", NULL,
|
||||
0, NULL);
|
||||
|
||||
if (!virCapabilitiesAddGuestDomain(guest, VIR_DOMAIN_VIRT_LXC, NULL, NULL, 0, NULL))
|
||||
goto error;
|
||||
|
||||
|
||||
if ((guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_EXE,
|
||||
VIR_ARCH_X86_64,
|
||||
"/usr/libexec/libvirt_lxc", NULL,
|
||||
0, NULL)) == NULL)
|
||||
goto error;
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_EXE,
|
||||
VIR_ARCH_X86_64,
|
||||
"/usr/libexec/libvirt_lxc", NULL,
|
||||
0, NULL);
|
||||
|
||||
if (!virCapabilitiesAddGuestDomain(guest, VIR_DOMAIN_VIRT_LXC, NULL, NULL, 0, NULL))
|
||||
goto error;
|
||||
|
@ -165,14 +165,9 @@ testQemuAddGuest(virCaps *caps,
|
||||
if (machines == NULL)
|
||||
goto error;
|
||||
|
||||
if (!(guest = virCapabilitiesAddGuest(caps,
|
||||
VIR_DOMAIN_OSTYPE_HVM,
|
||||
arch,
|
||||
qemu_emulators[emu_arch],
|
||||
NULL,
|
||||
nmachines,
|
||||
machines)))
|
||||
goto error;
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM,
|
||||
arch, qemu_emulators[emu_arch],
|
||||
NULL, nmachines, machines);
|
||||
|
||||
machines = NULL;
|
||||
nmachines = 0;
|
||||
|
@ -34,12 +34,11 @@ testXLInitCaps(void)
|
||||
nmachines = G_N_ELEMENTS(x86_machines);
|
||||
if ((machines = virCapabilitiesAllocMachines(x86_machines, nmachines)) == NULL)
|
||||
goto cleanup;
|
||||
if ((guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM,
|
||||
VIR_ARCH_X86_64,
|
||||
"/usr/lib/xen/bin/qemu-system-i386",
|
||||
"/usr/lib/xen/boot/hvmloader",
|
||||
nmachines, machines)) == NULL)
|
||||
goto cleanup;
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM,
|
||||
VIR_ARCH_X86_64,
|
||||
"/usr/lib/xen/bin/qemu-system-i386",
|
||||
"/usr/lib/xen/boot/hvmloader",
|
||||
nmachines, machines);
|
||||
machines = NULL;
|
||||
if (virCapabilitiesAddGuestDomain(guest, VIR_DOMAIN_VIRT_XEN, NULL,
|
||||
NULL, 0, NULL) == NULL)
|
||||
@ -48,12 +47,11 @@ testXLInitCaps(void)
|
||||
if ((machines = virCapabilitiesAllocMachines(xen_machines, nmachines)) == NULL)
|
||||
goto cleanup;
|
||||
|
||||
if ((guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_XEN,
|
||||
VIR_ARCH_X86_64,
|
||||
"/usr/lib/xen/bin/qemu-system-i386",
|
||||
NULL,
|
||||
nmachines, machines)) == NULL)
|
||||
goto cleanup;
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_XEN,
|
||||
VIR_ARCH_X86_64,
|
||||
"/usr/lib/xen/bin/qemu-system-i386",
|
||||
NULL,
|
||||
nmachines, machines);
|
||||
machines = NULL;
|
||||
|
||||
if (virCapabilitiesAddGuestDomain(guest, VIR_DOMAIN_VIRT_XEN, NULL,
|
||||
@ -63,12 +61,11 @@ testXLInitCaps(void)
|
||||
if ((machines = virCapabilitiesAllocMachines(pvh_machines, nmachines)) == NULL)
|
||||
goto cleanup;
|
||||
|
||||
if ((guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_XENPVH,
|
||||
VIR_ARCH_X86_64,
|
||||
"/usr/lib/xen/bin/qemu-system-i386",
|
||||
NULL,
|
||||
nmachines, machines)) == NULL)
|
||||
goto cleanup;
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_XENPVH,
|
||||
VIR_ARCH_X86_64,
|
||||
"/usr/lib/xen/bin/qemu-system-i386",
|
||||
NULL,
|
||||
nmachines, machines);
|
||||
machines = NULL;
|
||||
|
||||
if (virCapabilitiesAddGuestDomain(guest, VIR_DOMAIN_VIRT_XEN, NULL,
|
||||
|
@ -31,13 +31,9 @@ testCapsInit(void)
|
||||
virCapabilitiesAddHostMigrateTransport(caps, "vpxmigr");
|
||||
|
||||
/* i686 guest */
|
||||
guest =
|
||||
virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM,
|
||||
VIR_ARCH_I686,
|
||||
NULL, NULL, 0, NULL);
|
||||
|
||||
if (guest == NULL)
|
||||
goto failure;
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM,
|
||||
VIR_ARCH_I686,
|
||||
NULL, NULL, 0, NULL);
|
||||
|
||||
if (virCapabilitiesAddGuestDomain(guest, VIR_DOMAIN_VIRT_VMWARE, NULL, NULL, 0,
|
||||
NULL) == NULL) {
|
||||
@ -45,13 +41,9 @@ testCapsInit(void)
|
||||
}
|
||||
|
||||
/* x86_64 guest */
|
||||
guest =
|
||||
virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM,
|
||||
VIR_ARCH_X86_64,
|
||||
NULL, NULL, 0, NULL);
|
||||
|
||||
if (guest == NULL)
|
||||
goto failure;
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM,
|
||||
VIR_ARCH_X86_64,
|
||||
NULL, NULL, 0, NULL);
|
||||
|
||||
if (virCapabilitiesAddGuestDomain(guest, VIR_DOMAIN_VIRT_VMWARE, NULL, NULL, 0,
|
||||
NULL) == NULL) {
|
||||
|
@ -32,13 +32,9 @@ testCapsInit(void)
|
||||
|
||||
|
||||
/* i686 guest */
|
||||
guest =
|
||||
virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM,
|
||||
VIR_ARCH_I686,
|
||||
NULL, NULL, 0, NULL);
|
||||
|
||||
if (guest == NULL)
|
||||
goto failure;
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM,
|
||||
VIR_ARCH_I686,
|
||||
NULL, NULL, 0, NULL);
|
||||
|
||||
if (virCapabilitiesAddGuestDomain(guest, VIR_DOMAIN_VIRT_VMWARE, NULL, NULL, 0,
|
||||
NULL) == NULL) {
|
||||
@ -46,13 +42,9 @@ testCapsInit(void)
|
||||
}
|
||||
|
||||
/* x86_64 guest */
|
||||
guest =
|
||||
virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM,
|
||||
VIR_ARCH_X86_64,
|
||||
NULL, NULL, 0, NULL);
|
||||
|
||||
if (guest == NULL)
|
||||
goto failure;
|
||||
guest = virCapabilitiesAddGuest(caps, VIR_DOMAIN_OSTYPE_HVM,
|
||||
VIR_ARCH_X86_64,
|
||||
NULL, NULL, 0, NULL);
|
||||
|
||||
if (virCapabilitiesAddGuestDomain(guest, VIR_DOMAIN_VIRT_VMWARE, NULL, NULL, 0,
|
||||
NULL) == NULL) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user