[libvirt] [PATCH] Fix handling of blkio deviceWeight empty string
Eric Blake
eblake at redhat.com
Fri Mar 16 14:26:08 UTC 2012
On 03/16/2012 05:07 AM, Daniel P. Berrange wrote:
> From: "Daniel P. Berrange" <berrange at redhat.com>
>
> A common coding pattern for changing blkio parameters is
>
> 1. virDomainGetBlkioParameters
>
> 2. change one or more params
>
> 3. virDomainSetBlkioParameters
>
> For this to work, it must be possible to roundtrip through
> the methods without error. Unforuntelty virDomainGetBlkioParameters
s/Unforuntelty/Unfortunately/
> will return "" for the deviceWeight parameter for guests by default,
> which virDomainSetBlkioParameters will then reject as invalid.
>
> This fixes the handling of "" to be a no-op, and also improves the
> error message to tell you what was invalid
> ---
> src/qemu/qemu_driver.c | 8 +++++++-
> 1 files changed, 7 insertions(+), 1 deletions(-)
ACK.
--
Eric Blake eblake at redhat.com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 620 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20120316/88152a7d/attachment-0001.sig>
More information about the libvir-list
mailing list