fix(xfa): initialize template parsing options completely

This commit is contained in:
Mex authored and GitHub committed 2026-11-14 20:19:33 +01:00
1 parent d158760043
commit b45fcae35d
1 file changed
+1 -1
+1 -1
View File
@@ -1266,7 +1266,7 @@ pub fn parse(xml: &str) -> Result<(Template, Vec<String>), XfaError> {
crate::MAX_XML_DEPTH
)));
}
let opts = || crate::xml::ParsingOptions { allow_dtd: false, nodes_limit: MAX_NODES, ..Default::default() };
let opts = || crate::xml::ParsingOptions { allow_dtd: false, nodes_limit: MAX_NODES };
let doc = crate::xml::Document::parse_with_options(xml, opts()).map_err(|e| XfaError::Malformed(format!("template XML: {e}")))?;
let root = doc.root_element();
// The XDP's config packet has a <template> element too: the one we want is in the