Ondra Machacek has submitted this change and it was merged.
Change subject: Fix reading of lists of elements
......................................................................
Fix reading of lists of elements
Currently the method that read lists of elements doesn't handle
correctly empty elements without close tags. For example, when reading
the following cluster:
<cluster>
...
<required_rng_sources/>
<switch_type>legacy</switch_type>
</cluster>
The 'legacy' value of the 'switch_type' element is interpreted as one of
the values of the previous 'required_rng_sources' list.
This patch fixes the method and introduces two tests to verify that it
works correctly.
Change-Id: I76c3625719c5e2ef327fcee7cec974d740d5f655
Bug-Url:
https://bugzilla.redhat.com/1373431
Signed-off-by: Juan Hernandez <juan.hernandez(a)redhat.com>
(cherry picked from commit 576f99f2223d816450bfd05d594873213ece463a)
---
M sdk/ext/ov_xml_reader.c
A sdk/tests/test_cluster_reader.py
M sdk/tests/test_xml_reader.py
3 files changed, 101 insertions(+), 10 deletions(-)
Approvals:
Ondra Machacek: Looks good to me, approved
Juan Hernandez: Verified
Jenkins CI: Passed CI tests
--
To view, visit
https://gerrit.ovirt.org/63388
To unsubscribe, visit
https://gerrit.ovirt.org/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I76c3625719c5e2ef327fcee7cec974d740d5f655
Gerrit-PatchSet: 2
Gerrit-Project: ovirt-engine-sdk
Gerrit-Branch: sdk_4.0
Gerrit-Owner: Ondra Machacek <omachace(a)redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Juan Hernandez <juan.hernandez(a)redhat.com>
Gerrit-Reviewer: Ondra Machacek <omachace(a)redhat.com>
Gerrit-Reviewer: gerrit-hooks <automation(a)ovirt.org>