diff options
Diffstat (limited to 'Master/texmf-dist/tex/luatex/luaxml/luaxml-domobject.lua')
-rw-r--r-- | Master/texmf-dist/tex/luatex/luaxml/luaxml-domobject.lua | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/Master/texmf-dist/tex/luatex/luaxml/luaxml-domobject.lua b/Master/texmf-dist/tex/luatex/luaxml/luaxml-domobject.lua index 64daa88364f..413947b5d4c 100644 --- a/Master/texmf-dist/tex/luatex/luaxml/luaxml-domobject.lua +++ b/Master/texmf-dist/tex/luatex/luaxml/luaxml-domobject.lua @@ -134,13 +134,17 @@ end -- @return DOM_Object local parse = function( xmltext --- String to be parsed + ,voidElements --- hash table with void elements ) local domHandler = handler.domHandler() --- @type DOM_Object local DOM_Object = xml.xmlParser(domHandler) -- preserve whitespace DOM_Object.options.stripWS = nil - DOM_Object._handler.options.voidElements = void + -- don't try to expand entities + DOM_Object.options.expandEntities = nil + local voidElements = voidElements or void + DOM_Object._handler.options.voidElements = voidElements DOM_Object:parse(xmltext) DOM_Object.current = DOM_Object._handler.root DOM_Object.__index = DOM_Object |