com php-src: call ctor if it's not done yet: TSRM/TSRM.c
| From: | Anatol Belski | Date: | Wed, 24 Sep 2014 00:11:05 +0000 |
| Subject: | com php-src: call ctor if it's not done yet: TSRM/TSRM.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-81891@lists.php.net to get a copy of this message | ||
Commit: aa8c424e0f4cc4d725d2437f07ace2390a90ff2e
Author: Anatol Belski <ab@php.net> Wed, 24 Sep 2014 02:11:05 +0200
Parents: 58a2b05d7b5d4a9b3c3ac24ac82fdb958965dd05
Branches: native-tls
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=aa8c424e0f4cc4d725d2437f07ace2390a90ff2e
Log:
call ctor if it's not done yet
Changed paths:
M TSRM/TSRM.c
Diff:
diff --git a/TSRM/TSRM.c b/TSRM/TSRM.c
index b4206b6..82d8413 100644
--- a/TSRM/TSRM.c
+++ b/TSRM/TSRM.c
@@ -333,7 +333,7 @@ static void allocate_new_resource(tsrm_tls_entry **thread_resources_ptr, THREAD_
CALL_NEW_THREAD_BEGIN_HANDLER(thread_id, &(*thread_resources_ptr)->storage);
}
for (i=0; i<id_count; i++) {
- if (resource_types_table[i].done) {
+ if (!resource_types_table[i].done) {
if (resource_types_table[i].ctor) {
CALL_TSRMG_CTOR(resource_types_table[i].ctor, TSRMG_PTR((*thread_resources_ptr)->storage,
resource_types_table[i].offset), &(*thread_resources_ptr)->storage);
}