On 12/01/2011 12:55 AM, Lei Li wrote: > Fix a logic error, the initial value of ret = -1, if just set --config, > it will goto endjob directly without doing its really job here. > > > Signed-off-by: Lei Li <lilei@xxxxxxxxxxxxxxxxxx> > --- > src/qemu/qemu_driver.c | 2 -- > 1 files changed, 0 insertions(+), 2 deletions(-) > > diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c > index ed90c66..8ea6f48 100644 > --- a/src/qemu/qemu_driver.c > +++ b/src/qemu/qemu_driver.c > @@ -11234,8 +11234,6 @@ qemuDomainSetBlockIoTune(virDomainPtr dom, > ret = qemuMonitorSetBlockIoThrottle(priv->mon, device, &info); > qemuDomainObjExitMonitorWithDriver(driver, vm); > } > - if (ret < 0) > - goto endjob; Not quite right - we don't want to affect config if live failed. Rather, move the } to be after the (ret < 0) check. ACK with this squashed in, and pushed. diff --git i/src/qemu/qemu_driver.c w/src/qemu/qemu_driver.c index 8ea6f48..1e5ed9a 100644 --- i/src/qemu/qemu_driver.c +++ w/src/qemu/qemu_driver.c @@ -11233,6 +11233,8 @@ qemuDomainSetBlockIoTune(virDomainPtr dom, qemuDomainObjEnterMonitorWithDriver(driver, vm); ret = qemuMonitorSetBlockIoThrottle(priv->mon, device, &info); qemuDomainObjExitMonitorWithDriver(driver, vm); + if (ret < 0) + goto endjob; } if (flags & VIR_DOMAIN_AFFECT_CONFIG) { -- Eric Blake eblake@xxxxxxxxxx +1-919-301-3266 Libvirt virtualization library http://libvirt.org
Attachment:
signature.asc
Description: OpenPGP digital signature
-- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list