[libvirt] [PATCH] virsh: Print error message if argument parsing fails for cmdNodesuspend
Eric Blake
eblake at redhat.com
Tue Dec 13 15:08:25 UTC 2011
On 12/13/2011 07:31 AM, Michal Privoznik wrote:
>>
>> - if (vshCommandOptString(cmd, "target", &target) < 0)
>> + if (vshCommandOptString(cmd, "target", &target) < 0) {
>> + vshError(ctl, _("Invalid suspend target argument"));
> I'd do s/suspend // in all strings you're adding.
Compilation without NLS will trigger gcc warnings that you are using a
printf-style interface without any %. Write this as vshError(ctl, "%s",
_("Invalid target argument")).
--
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/20111213/041afdaa/attachment-0001.sig>
More information about the libvir-list
mailing list