[libvirt] [PATCHv3 3/4] util: Add helper to assign typed params from string
Eric Blake
eblake at redhat.com
Thu Sep 6 23:01:27 UTC 2012
On 09/06/2012 08:01 AM, Peter Krempa wrote:
> This patch adds a helper to deal with assigning values to
> virTypedParameter structures from strings. The helper parses the value
> from the string and assigns it to the corresponding union value.
> ---
> New in series.
> + case VIR_TYPED_PARAM_ULLONG:
> + if (virStrToLong_ull(val, NULL, 10, ¶m->value.ul) < 0) {
> + virReportError(VIR_ERR_INVALID_ARG,
> + _("Invalid value for field '%s': "
> + "expected long long"),
expected unsigned long long
--
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: 617 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20120906/e6660a49/attachment-0001.sig>
More information about the libvir-list
mailing list