mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-22 03:12:22 +00:00
qemu: Drop useless SPICE migration code
The spiceMigration flag will never be true if there is no SPICE graphics configured for the domain. https://bugzilla.redhat.com/show_bug.cgi?id=1151723 Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
This commit is contained in:
parent
a16ea1a0f3
commit
f34b981e40
@ -2522,23 +2522,11 @@ static int
|
||||
qemuMigrationWaitForSpice(virDomainObjPtr vm)
|
||||
{
|
||||
qemuDomainObjPrivatePtr priv = vm->privateData;
|
||||
bool wait_for_spice = false;
|
||||
size_t i = 0;
|
||||
|
||||
if (!virQEMUCapsGet(priv->qemuCaps, QEMU_CAPS_SEAMLESS_MIGRATION) ||
|
||||
!priv->job.spiceMigration)
|
||||
return 0;
|
||||
|
||||
for (i = 0; i < vm->def->ngraphics; i++) {
|
||||
if (vm->def->graphics[i]->type == VIR_DOMAIN_GRAPHICS_TYPE_SPICE) {
|
||||
wait_for_spice = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (!wait_for_spice)
|
||||
return 0;
|
||||
|
||||
VIR_DEBUG("Waiting for SPICE to finish migration");
|
||||
while (!priv->job.spiceMigrated && !priv->job.abortJob) {
|
||||
if (virDomainObjWait(vm) < 0)
|
||||
|
Loading…
x
Reference in New Issue
Block a user