Error reporting didn't work correctly when an error happended on
the root level of the tree.
This patch adds the position information to the root as well.
Signed-off-by: Radek Pazdera <rpazdera(a)redhat.com>
---
Common/XmlProcessing.py | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/Common/XmlProcessing.py b/Common/XmlProcessing.py
index e225309..0f1aa0c 100644
--- a/Common/XmlProcessing.py
+++ b/Common/XmlProcessing.py
@@ -122,6 +122,8 @@ class XmlDomTreeInit:
exc.set_pos(pos)
raise exc
+ pos = {"file": self._filename, "line": 0, "col":
0}
+ dom.parse_position = pos
return dom
--
1.7.7.6