[PHP-CVS] com php-src: Copy default properties of internal classes for different threads: Zend/zend_API.c
Commit:ea3e0d5a7370df63af9372780b91a749fda773b1 Author:Johannes Schlüter Thu, 5 Apr 2012 18:46:52 +0200 Committer: Stanislav Malyshev Wed, 11 Apr 2012 20:21:59 -0700 Parents: 7495c5e1d404d251d8c9c521fd80c85cd4e2fad1 Branches: PHP-5.4.1 Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=ea3e0d5a7370df63af9372780b91a749fda773b1 Log: Copy default properties of internal classes for different threads Changed paths: M Zend/zend_API.c Diff: diff --git a/Zend/zend_API.c b/Zend/zend_API.c index 71feccf..98a33e5 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -1093,7 +1093,12 @@ ZEND_API void object_properties_init(zend_object *object, zend_class_entry *clas for (i = 0; i < class_type->default_properties_count; i++) { object->properties_table[i] = class_type->default_properties_table[i]; if (class_type->default_properties_table[i]) { +#if ZTS + ALLOC_ZVAL( object->properties_table[i]); + MAKE_COPY_ZVAL(&class_type->default_properties_table[i], object->properties_table[i]); +#else Z_ADDREF_P(object->properties_table[i]); +#endif } } object->properties = NULL; -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-CVS] com php-src: Copy default properties of internal classes for different threads: Zend/zend_API.c
Commit:82c05eeda99e646063abece28c2b1a7c0a414338 Author:Johannes Schlüter Thu, 5 Apr 2012 18:46:52 +0200 Committer: Stanislav Malyshev Wed, 11 Apr 2012 19:21:41 -0700 Parents: 05c8d4766c272e101b5279f0ec432e1b16e74637 Branches: PHP-5.4 Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=82c05eeda99e646063abece28c2b1a7c0a414338 Log: Copy default properties of internal classes for different threads Changed paths: M Zend/zend_API.c Diff: diff --git a/Zend/zend_API.c b/Zend/zend_API.c index 71feccf..98a33e5 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -1093,7 +1093,12 @@ ZEND_API void object_properties_init(zend_object *object, zend_class_entry *clas for (i = 0; i < class_type->default_properties_count; i++) { object->properties_table[i] = class_type->default_properties_table[i]; if (class_type->default_properties_table[i]) { +#if ZTS + ALLOC_ZVAL( object->properties_table[i]); + MAKE_COPY_ZVAL(&class_type->default_properties_table[i], object->properties_table[i]); +#else Z_ADDREF_P(object->properties_table[i]); +#endif } } object->properties = NULL; -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php