diff options
author | Shaun McCance <shaunm@redhat.com> | 2017-08-15 10:37:47 -0400 |
---|---|---|
committer | Shaun McCance <shaunm@redhat.com> | 2017-08-15 10:37:47 -0400 |
commit | 14f428652bc44d0f65cf21f17afaf1e0b13f0336 (patch) | |
tree | c264d88814b857bc5023d64dc83dcd2d7e7be811 | |
parent | 676f3f738b21ec4d77f300f83d31d2d0eceaddcc (diff) | |
download | itstool-14f428652bc44d0f65cf21f17afaf1e0b13f0336.tar.gz |
Fix keep entities mode after libxml2 changes
https://bugzilla.gnome.org/show_bug.cgi?id=762110
-rwxr-xr-x | itstool.in | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -458,6 +458,7 @@ class Document (object): if load_dtd: ctxt.loadSubset(1) if keep_entities: + ctxt.ctxtUseOptions(libxml2.XML_PARSE_DTDLOAD) ctxt.replaceEntities(0) else: ctxt.replaceEntities(1) @@ -1014,6 +1015,7 @@ class Document (object): ctxt = libxml2.createDocParserCtxt(blurb) if self._load_dtd: ctxt.loadSubset(1) + ctxt.ctxtUseOptions(libxml2.XML_PARSE_DTDLOAD) ctxt.replaceEntities(0) ctxt.parseDocument() trnode = ctxt.doc().getRootElement() |