forked from pool/libvirt
24511ba7f9
e4d131b8-mv-virDomainDefPostParseInternal.patch, 3e428670-post-parse-implicit-video.patch, 538012c8-default-vram.patch, 96b21fb0-vram-tests.patch, 400e716d-libxl-noprope-emulator.patch, b90c4b5f-tests-use-qemu-xen.patch bsc#979397 OBS-URL: https://build.opensuse.org/package/show/Virtualization/libvirt?expand=0&rev=528
38 lines
1.4 KiB
Diff
38 lines
1.4 KiB
Diff
commit 400e716d7d8371fa718c27bb4f05b9a68929e64a
|
|
Author: Jim Fehlig <jfehlig@suse.com>
|
|
Date: Thu May 12 14:40:28 2016 -0600
|
|
|
|
libxl: don't attempt to probe a non-existent emulator
|
|
|
|
When probing the <emulator> with '-help' to determine if
|
|
it is the old qemu, errors are reported if the emulator
|
|
doesn't exist
|
|
|
|
libvirt: error : internal error: Child process
|
|
(/usr/lib/xen/bin/qemu-dm -help) unexpected exit status 127:
|
|
libvirt: error : cannot execute binary /usr/lib/xen/bin/qemu-dm:
|
|
No such file or directory
|
|
|
|
Avoid the probe if the specified emulator doesn't exist,
|
|
squelching the error. There is no behavior change since
|
|
libxlDomainGetEmulatorType() would return
|
|
LIBXL_DEVICE_MODEL_VERSION_QEMU_XEN if the probe failed
|
|
via virCommandRun().
|
|
|
|
Signed-off-by: Jim Fehlig <jfehlig@suse.com>
|
|
|
|
Index: libvirt-1.3.4/src/libxl/libxl_conf.c
|
|
===================================================================
|
|
--- libvirt-1.3.4.orig/src/libxl/libxl_conf.c
|
|
+++ libvirt-1.3.4/src/libxl/libxl_conf.c
|
|
@@ -916,6 +916,9 @@ libxlDomainGetEmulatorType(const virDoma
|
|
|
|
if (def->os.type == VIR_DOMAIN_OSTYPE_HVM) {
|
|
if (def->emulator) {
|
|
+ if (!virFileExists(def->emulator))
|
|
+ goto cleanup;
|
|
+
|
|
cmd = virCommandNew(def->emulator);
|
|
|
|
virCommandAddArgList(cmd, "-help", NULL);
|