We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a3f0861 commit 19fc6edCopy full SHA for 19fc6ed
1 file changed
ext/soap/php_xml.c
@@ -79,12 +79,15 @@ static xmlDocPtr soap_xmlParse_ex(xmlParserCtxtPtr ctxt)
79
{
80
xmlDocPtr ret;
81
if (ctxt) {
82
+#if LIBXML_VERSION >= 21300
83
+ xmlCtxtSetOptions(ctxt, XML_PARSE_HUGE | XML_PARSE_NO_XXE | XML_PARSE_NONET | XML_PARSE_NOBLANKS);
84
+#else
85
php_libxml_sanitize_parse_ctxt_options(ctxt);
- /* TODO: In libxml2 2.14.0 change this to the new options API so we don't rely on deprecated APIs. */
86
ZEND_DIAGNOSTIC_IGNORED_START("-Wdeprecated-declarations")
87
ctxt->keepBlanks = 0;
88
ctxt->options |= XML_PARSE_HUGE;
89
ZEND_DIAGNOSTIC_IGNORED_END
90
+#endif
91
ctxt->sax->ignorableWhitespace = soap_ignorableWhitespace;
92
ctxt->sax->comment = soap_Comment;
93
ctxt->sax->warning = NULL;
0 commit comments