qemu: Need to check for capability before query

Prior to trying the query-iothreads call - check if the qemu has
the capability

Signed-off-by: John Ferlan <jferlan@redhat.com>
This commit is contained in:
John Ferlan 2014-09-16 05:57:28 -04:00
parent e6fc664618
commit 76a81b1d31

View File

@ -2105,6 +2105,9 @@ qemuProcessDetectIOThreadPIDs(virQEMUDriverPtr driver,
int ret = -1;
size_t i;
if (!virQEMUCapsGet(priv->qemuCaps, QEMU_CAPS_OBJECT_IOTHREAD))
return 0;
/* Get the list of IOThreads from qemu */
if (qemuDomainObjEnterMonitorAsync(driver, vm, asyncJob) < 0)
goto cleanup;