com php-src: Initialize CG(one_time_string) in ZTS as well: Zend/zend_string.c ext/pdo/pdo_dbh. c
Commit: 211d32c81429730e2692c65577d021616a525726
Author: Nikita Popov <nikic@php.net> Mon, 5 May 2014 21:16:49 +0200
Parents: b9438a1ec7a2548e05b938f8034f74f9c7d490f0
Branches: phpng
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=211d32c81429730e2692c65577d021616a525726
Log:
Initialize CG(one_time_string) in ZTS as well
Changed paths:
M Zend/zend_string.c
M ext/pdo/pdo_dbh.c
Diff:
diff --git a/Zend/zend_string.c b/Zend/zend_string.c
index 80571ec..360ff29 100644
--- a/Zend/zend_string.c
+++ b/Zend/zend_string..c
@@ -57,9 +57,6 @@ void zend_interned_strings_init(TSRMLS_D)
str = STR_ALLOC(sizeof("")-1, 1);
str->val[0] = '\000';
CG(empty_string) = zend_new_interned_string_int(str TSRMLS_CC);
-
- /* one char strings (the actual interned strings are going to be created by ext/opcache) */
- memset(CG(one_char_string), 0, sizeof(CG(one_char_string)));
#else
str = STR_ALLOC(sizeof("")-1, 1);
str->val[0] = '\000';
@@ -67,6 +64,9 @@ void zend_interned_strings_init(TSRMLS_D)
CG(empty_string) = str;
#endif
+ /* one char strings (the actual interned strings are going to be created by ext/opcache) */
+ memset(CG(one_char_string), 0, sizeof(CG(one_char_string)));
+
zend_new_interned_string = zend_new_interned_string_int;
zend_interned_strings_snapshot = zend_interned_strings_snapshot_int;
zend_interned_strings_restore = zend_interned_strings_restore_int;
diff --git a/ext/pdo/pdo_dbh.c b/ext/pdo/pdo_dbh.c
index a9032d0..c5b2b9f 100644
--- a/ext/pdo/pdo_dbh.c
+++ b/ext/pdo/pdo_dbh.c
@@ -1544,7 +1544,7 @@ static void pdo_dbh_free_storage(zend_object *std TSRMLS_DC)
dbh->methods->persistent_shutdown(dbh TSRMLS_CC);
}
zend_object_std_dtor(std TSRMLS_CC);
- dbh_free(dbh);
+ dbh_free(dbh TSRMLS_CC);
}
zend_object *pdo_dbh_new(zend_class_entry *ce TSRMLS_DC)
Thread (1 message)
- Nikita Popov