[libvirt] [PATCH] esx: Fix esxVI_String_Deserialize
Eric Blake
eblake at redhat.com
Wed Jul 18 22:55:43 UTC 2012
On 07/18/2012 04:48 PM, Matthias Bolte wrote:
> It was broken since forever as it expected a libxml2
> XML_ELEMENT_NODE containing a XML_TEXT_NODE instead of
> just a XML_TEXT_NODE.
>
> This problem was not discovered for so long because
> esxVI_String_Deserialize was not used until now.
>
> Reported by Ata Bohra
> ---
> src/esx/esx_vi_types.c | 23 +++++++++++++++++++----
> 1 files changed, 19 insertions(+), 4 deletions(-)
ACK. Even though you're adding lines of code...
> -/* esxVI_String_Deserialize */
> -ESX_VI__TEMPLATE__DESERIALIZE(String,
..the old code was a macro expanding into a much larger unwrap
operation, and your new code is a subset of that with less unwrapping.
> + if (string == NULL || *string != NULL) {
> + ESX_VI_ERROR(VIR_ERR_INTERNAL_ERROR, "%s", _("Invalid argument"));
Conflict magnet, depending on whether your patch or Dan's error cleanup
patch goes in first.
--
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/20120718/917a45cf/attachment-0001.sig>
More information about the libvir-list
mailing list