[libvirt] [PATCH 0/2] Need to set booleans in right place for hotplug cleanup

After pushing and working on the next set of changes, I realized that the setting of some booleans needed to be inside an if condition <sigh>. John Ferlan (2): qemu: Move setting of obj bools for qemuDomainAttachVirtioDiskDevice qemu: Move setting of encobjAdded for qemuDomainAttachSCSIDisk src/qemu/qemu_hotplug.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) -- 2.5.5

A post push realization that the setting of the boolean needed to be inside the if condition. Signed-off-by: John Ferlan <jferlan@redhat.com> --- src/qemu/qemu_hotplug.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/qemu/qemu_hotplug.c b/src/qemu/qemu_hotplug.c index 5e18d34..aee62bb 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; -- 2.5.5

A post push realization that the boolean should be set inside the condition Signed-off-by: John Ferlan <jferlan@redhat.com> --- src/qemu/qemu_hotplug.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/qemu/qemu_hotplug.c b/src/qemu/qemu_hotplug.c index aee62bb..cdad7ef 100644 --- a/src/qemu/qemu_hotplug.c +++ b/src/qemu/qemu_hotplug.c @@ -651,8 +651,8 @@ qemuDomainAttachSCSIDisk(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; -- 2.5.5

On Tue, Jul 19, 2016 at 10:54:48AM -0400, John Ferlan wrote:
After pushing and working on the next set of changes, I realized that the setting of some booleans needed to be inside an if condition <sigh>.
John Ferlan (2): qemu: Move setting of obj bools for qemuDomainAttachVirtioDiskDevice qemu: Move setting of encobjAdded for qemuDomainAttachSCSIDisk
src/qemu/qemu_hotplug.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
ACK series Jan
participants (2)
-
John Ferlan
-
Ján Tomko