aboutsummaryrefslogtreecommitdiff
path: root/gnu/packages/patches/chromium-system-libxml.patch
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/packages/patches/chromium-system-libxml.patch')
-rw-r--r--gnu/packages/patches/chromium-system-libxml.patch29
1 files changed, 29 insertions, 0 deletions
diff --git a/gnu/packages/patches/chromium-system-libxml.patch b/gnu/packages/patches/chromium-system-libxml.patch
new file mode 100644
index 0000000000..23c42d79cb
--- /dev/null
+++ b/gnu/packages/patches/chromium-system-libxml.patch
@@ -0,0 +1,29 @@
+description: system libxml2 2.9.4 does not yet provide XML_PARSE_NOXXE
+author: Michael Gilbert <mgilbert@debian.org>
+
+Copied from:
+
+https://anonscm.debian.org/cgit/pkg-chromium/pkg-chromium.git/tree/debian/patches/system/libxml.patch
+
+--- a/third_party/libxml/chromium/libxml_utils.cc
++++ b/third_party/libxml/chromium/libxml_utils.cc
+@@ -24,8 +24,7 @@ XmlReader::~XmlReader() {
+
+ bool XmlReader::Load(const std::string& input) {
+ const int kParseOptions = XML_PARSE_RECOVER | // recover on errors
+- XML_PARSE_NONET | // forbid network access
+- XML_PARSE_NOXXE; // no external entities
++ XML_PARSE_NONET; // forbid network access
+ // TODO(evanm): Verify it's OK to pass NULL for the URL and encoding.
+ // The libxml code allows for these, but it's unclear what effect is has.
+ reader_ = xmlReaderForMemory(input.data(), static_cast<int>(input.size()),
+@@ -35,8 +34,7 @@ bool XmlReader::Load(const std::string&
+
+ bool XmlReader::LoadFile(const std::string& file_path) {
+ const int kParseOptions = XML_PARSE_RECOVER | // recover on errors
+- XML_PARSE_NONET | // forbid network access
+- XML_PARSE_NOXXE; // no external entities
++ XML_PARSE_NONET; // forbid network access
+ reader_ = xmlReaderForFile(file_path.c_str(), NULL, kParseOptions);
+ return reader_ != NULL;
+ }