]> git.ipfire.org Git - thirdparty/libvirt.git/commit
qemuMigrationCookieNetworkXMLFormat: Refactor XML formatting
authorPeter Krempa <pkrempa@redhat.com>
Wed, 30 Sep 2020 13:30:20 +0000 (15:30 +0200)
committerPeter Krempa <pkrempa@redhat.com>
Mon, 5 Oct 2020 13:58:52 +0000 (15:58 +0200)
commit84589ac004955301702f1ccd17a6df05a60740ec
tree0622d6e3bed0ba079bf6edf1fda7f74b359d4d2d
parent592a9a859a31b8a044d1b1af91ad239e17edb92a
qemuMigrationCookieNetworkXMLFormat: Refactor XML formatting

Use 'virXMLFormatElement' both for formating the whole <network> element
but also for formatting the <interface> subelements. This alows to
remove the crazy logic which was determining which element was already
formatted.

Additional simplification is achieved by switching to skipping the loop
using 'continue' rather than putting everything in a giant block.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
src/qemu/qemu_migration_cookie.c