[libvirt] [PATCH] Clarify an error message in setmem.
Eric Blake
eblake at redhat.com
Mon Apr 5 20:58:01 UTC 2010
On 04/05/2010 11:37 AM, Chris Lalancette wrote:
> Signed-off-by: Chris Lalancette <clalance at redhat.com>
> ---
> tools/virsh.c | 3 ++-
> 1 files changed, 2 insertions(+), 1 deletions(-)
>
> diff --git a/tools/virsh.c b/tools/virsh.c
> index ad64bc0..d241fa0 100644
> --- a/tools/virsh.c
> +++ b/tools/virsh.c
> @@ -2407,7 +2407,8 @@ cmdSetmem(vshControl *ctl, const vshCmd *cmd)
>
> if (kilobytes > info.maxMem) {
> virDomainFree(dom);
> - vshError(ctl, _("Invalid value of %d for memory size"), kilobytes);
> + vshError(ctl, _("Requested memory size %d kb is larger than maximum of %lu kb"),
> + kilobytes, info.maxMem);
ACK to the wording change.
But why is kilobytes int, while info.maxMem is unsigned long? Could
that ever bite us when converting 32-bit kilobytes to 64-bit unsigned?
--
Eric Blake eblake at redhat.com +1-801-349-2682
Libvirt virtualization library http://libvirt.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 323 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20100405/3e3fc545/attachment-0001.sig>
More information about the libvir-list
mailing list