[librsvg/librsvg-2.40] Set replaceEntities where we set the rest of the XML parser's options
- From: Federico Mena Quintero <federico src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [librsvg/librsvg-2.40] Set replaceEntities where we set the rest of the XML parser's options
- Date: Wed, 4 Oct 2017 01:06:26 +0000 (UTC)
commit 4ab0f57e08ce1ab6db89a97d2fb7198f8437c518
Author: Federico Mena Quintero <federico gnome org>
Date: Tue Oct 3 18:43:29 2017 -0500
Set replaceEntities where we set the rest of the XML parser's options
It's a bit iffy that we do it by directly poking inside the
xmlParserCtxPtr...
rsvg-base.c | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
---
diff --git a/rsvg-base.c b/rsvg-base.c
index 3aee760..7282521 100644
--- a/rsvg-base.c
+++ b/rsvg-base.c
@@ -582,6 +582,11 @@ rsvg_set_xml_parse_options(xmlParserCtxtPtr xml_parser,
}
xmlCtxtUseOptions (xml_parser, options);
+
+ /* if false, external entities work, but internal ones don't. if true, internal entities
+ work, but external ones don't. favor internal entities, in order to not cause a
+ regression */
+ xml_parser->replaceEntities = TRUE;
}
/* http://www.w3.org/TR/xinclude/ */
@@ -1168,11 +1173,6 @@ create_xml_push_parser_ctxt (RsvgHandle *handle)
handle->priv->ctxt = xmlCreatePushParserCtxt (&rsvgSAXHandlerStruct, handle, NULL, 0,
rsvg_handle_get_base_uri (handle));
rsvg_set_xml_parse_options(handle->priv->ctxt, handle);
-
- /* if false, external entities work, but internal ones don't. if true, internal entities
- work, but external ones don't. favor internal entities, in order to not cause a
- regression */
- handle->priv->ctxt->replaceEntities = TRUE;
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]