mirror of
https://github.com/php/php-src.git
synced 2025-08-15 21:48:51 +02:00
Merge branch 'PHP-8.1' into PHP-8.2
This commit is contained in:
commit
deddf4692a
16 changed files with 274 additions and 12 deletions
|
@ -308,7 +308,7 @@ PHP_METHOD(XSLTProcessor, importStylesheet)
|
|||
xmlDoc *doc = NULL, *newdoc = NULL;
|
||||
xsltStylesheetPtr sheetp, oldsheetp;
|
||||
xsl_object *intern;
|
||||
int prevSubstValue, prevExtDtdValue, clone_docu = 0;
|
||||
int clone_docu = 0;
|
||||
xmlNode *nodep = NULL;
|
||||
zval *cloneDocu, rv;
|
||||
zend_string *member;
|
||||
|
@ -332,13 +332,12 @@ PHP_METHOD(XSLTProcessor, importStylesheet)
|
|||
stylesheet document otherwise the node proxies will be a mess */
|
||||
newdoc = xmlCopyDoc(doc, 1);
|
||||
xmlNodeSetBase((xmlNodePtr) newdoc, (xmlChar *)doc->URL);
|
||||
prevSubstValue = xmlSubstituteEntitiesDefault(1);
|
||||
prevExtDtdValue = xmlLoadExtDtdDefaultValue;
|
||||
PHP_LIBXML_SANITIZE_GLOBALS(parse);
|
||||
xmlSubstituteEntitiesDefault(1);
|
||||
xmlLoadExtDtdDefaultValue = XML_DETECT_IDS | XML_COMPLETE_ATTRS;
|
||||
|
||||
sheetp = xsltParseStylesheetDoc(newdoc);
|
||||
xmlSubstituteEntitiesDefault(prevSubstValue);
|
||||
xmlLoadExtDtdDefaultValue = prevExtDtdValue;
|
||||
PHP_LIBXML_RESTORE_GLOBALS(parse);
|
||||
|
||||
if (!sheetp) {
|
||||
xmlFreeDoc(newdoc);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue