From 659ded58eda816ecd451f933984b25a2bb3db47c Mon Sep 17 00:00:00 2001 From: Eric Blake Date: Mon, 14 Nov 2011 17:18:15 -0700 Subject: [PATCH] qemu: fix blkiotune --live --config Without this, 'virsh blkiotune --live --config --weight=n' only affected live. * src/qemu/qemu_driver.c (qemuDomainSetBlkioParameters): Allow setting both configurations at once. --- src/qemu/qemu_driver.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c index 307cc37680..7e87369c45 100644 --- a/src/qemu/qemu_driver.c +++ b/src/qemu/qemu_driver.c @@ -5979,7 +5979,10 @@ static int qemuDomainSetBlkioParameters(virDomainPtr dom, ret = -1; } } - } else if (flags & VIR_DOMAIN_AFFECT_CONFIG) { + } + if (ret < 0) + goto cleanup; + if (flags & VIR_DOMAIN_AFFECT_CONFIG) { /* Clang can't see that if we get here, persistentDef was set. */ sa_assert(persistentDef);