]> git.ipfire.org Git - thirdparty/libvirt.git/commit
virXMLParseHelper: Rework error reporting
authorPeter Krempa <pkrempa@redhat.com>
Wed, 14 Apr 2021 11:03:58 +0000 (13:03 +0200)
committerPeter Krempa <pkrempa@redhat.com>
Fri, 16 Apr 2021 11:17:35 +0000 (13:17 +0200)
commite87eeefb3e4380b553e491ebe05ba0af17531399
tree8e69762230b89ab8048c6aa512d6b1632c1f957f
parent5339ecf6b95d6f9ebc7b998e2982c1a7e9946b00
virXMLParseHelper: Rework error reporting

Move the reporting of parsing error on the error path of the parser as
other code paths report their own errors already.

Additionally prefer printing the 'url' as document name if provided
instead of "[inline data]" as that usually gives a better hint at least
which kind of XML is being parsed.

Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Tim Wiederhake <twiederh@redhat.com>
src/util/virxml.c