From: John Ferlan Date: Tue, 19 Jul 2016 14:48:10 +0000 (-0400) Subject: qemu: Move setting of obj bools for qemuDomainAttachVirtioDiskDevice X-Git-Tag: v2.1.0-rc1~82 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c144f14c120a3b4fd3b7cf87bf0bbc30183464a0;p=thirdparty%2Flibvirt.git qemu: Move setting of obj bools for qemuDomainAttachVirtioDiskDevice A post push realization that the setting of the boolean needed to be inside the if condition. --- diff --git a/src/qemu/qemu_hotplug.c b/src/qemu/qemu_hotplug.c index 5e18d344a8..aee62bb4e0 100644 --- a/src/qemu/qemu_hotplug.c +++ b/src/qemu/qemu_hotplug.c @@ -382,8 +382,8 @@ qemuDomainAttachVirtioDiskDevice(virConnectPtr conn, secobjProps = NULL; /* qemuMonitorAddObject consumes */ if (rv < 0) goto exit_monitor; + secobjAdded = true; } - secobjAdded = true; if (encobjProps) { rv = qemuMonitorAddObject(priv->mon, "secret", encinfo->s.aes.alias, @@ -391,8 +391,8 @@ qemuDomainAttachVirtioDiskDevice(virConnectPtr conn, encobjProps = NULL; /* qemuMonitorAddObject consumes */ if (rv < 0) goto exit_monitor; + encobjAdded = true; } - encobjAdded = true; if (qemuMonitorAddDrive(priv->mon, drivestr) < 0) goto exit_monitor;