com php-src: Fix Bug #64776 The XSLT extension is no t thread safe.: NEWS ext/xsl/php_xsl.c
| From: | Michael Wallner | Date: | Mon, 02 Dec 2013 14:01:24 +0000 |
| Subject: | com php-src: Fix Bug #64776 The XSLT extension is no t thread safe.: NEWS ext/xsl/php_xsl.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-74199@lists.php.net to get a copy of this message | ||
Commit: 7cd702640de648a4fd5d49234b9ce4704c007f5d
Author: Michael Wallner <mike@php.net> Mon, 2 Dec 2013 15:01:24 +0100
Parents: df484b00080a2da466721e63cee04eedf48fb59a
Branches: master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=7cd702640de648a4fd5d49234b9ce4704c007f5d
Log:
Fix Bug #64776 The XSLT extension is not thread safe.
Bugs:
https://bugs.php.net/64776
Changed paths:
M NEWS
M ext/xsl/php_xsl.c
Diff:
diff --git a/NEWS b/NEWS
index 5229ff4..e527eee 100644
--- a/NEWS
+++ b/NEWS
@@ -2,4 +2,7 @@ PHP NEWS
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
?? ??? 20??, PHP 5.7.0
+- XSL:
+ . Fixed bug #64776 (The XSLT extension is not thread safe). (Mike)
+
<<< NOTE: Insert NEWS from last stable release here prior to actual release! >>>
diff --git a/ext/xsl/php_xsl.c b/ext/xsl/php_xsl.c
index 41e1b9f..c3b901e 100644
--- a/ext/xsl/php_xsl.c
+++ b/ext/xsl/php_xsl.c
@@ -57,8 +57,8 @@ zend_module_entry xsl_module_entry = {
xsl_functions,
PHP_MINIT(xsl),
PHP_MSHUTDOWN(xsl),
- PHP_RINIT(xsl), /* Replace with NULL if there's nothing to do at request start */
- PHP_RSHUTDOWN(xsl), /* Replace with NULL if there's nothing to do at request end */
+ NULL,
+ NULL,
PHP_MINFO(xsl),
#if ZEND_MODULE_API_NO >= 20010901
"0.1", /* Replace with version number for your extension */
@@ -170,6 +170,7 @@ PHP_MINIT_FUNCTION(xsl)
xsltRegisterExtModuleFunction ((const xmlChar *) "function",
(const xmlChar *) "http://php.net/xsl",
xsl_ext_function_object_php);
+ xsltSetGenericErrorFunc(NULL, php_libxml_error_handler);
REGISTER_LONG_CONSTANT("XSL_CLONE_AUTO", 0, CONST_CS | CONST_PERSISTENT);
REGISTER_LONG_CONSTANT("XSL_CLONE_NEVER", -1, CONST_CS | CONST_PERSISTENT);
@@ -273,7 +274,7 @@ PHP_MSHUTDOWN_FUNCTION(xsl)
(const xmlChar *) "http://php.net/xsl");
xsltUnregisterExtModuleFunction ((const xmlChar *) "function",
(const xmlChar *) "http://php.net/xsl");
-
+ xsltSetGenericErrorFunc(NULL, NULL);
xsltCleanupGlobals();
UNREGISTER_INI_ENTRIES();
@@ -282,24 +283,6 @@ PHP_MSHUTDOWN_FUNCTION(xsl)
}
/* }}} */
-/* {{{ PHP_RINIT_FUNCTION
- */
-PHP_RINIT_FUNCTION(xsl)
-{
- xsltSetGenericErrorFunc(NULL, php_libxml_error_handler);
- return SUCCESS;
-}
-/* }}} */
-
-/* {{{ PHP_RSHUTDOWN_FUNCTION
- */
-PHP_RSHUTDOWN_FUNCTION(xsl)
-{
- xsltSetGenericErrorFunc(NULL, NULL);
- return SUCCESS;
-}
-/* }}} */
-
/* {{{ PHP_MINFO_FUNCTION
*/
PHP_MINFO_FUNCTION(xsl)