summaryrefslogtreecommitdiff
path: root/Zend/zend_API.c
diff options
context:
space:
mode:
authorZeev Suraski <zeev@php.net>1999-04-18 15:11:52 +0000
committerZeev Suraski <zeev@php.net>1999-04-18 15:11:52 +0000
commit342c6e0b2328db952709dd5a35c113e2b17c1e3d (patch)
treea43236d5e2474a8f55a6e5cb9ebd262da5374770 /Zend/zend_API.c
parent2e8fb4e329bf98eb33dffad4c5fb1b49f73e7517 (diff)
downloadphp-git-342c6e0b2328db952709dd5a35c113e2b17c1e3d.tar.gz
Whatnot:
* updated alloc_persist to use critical sections * changed extension shutdown to two-phase * updated dependencies * PR support (don't remember if there was any really)
Diffstat (limited to 'Zend/zend_API.c')
-rw-r--r--Zend/zend_API.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/Zend/zend_API.c b/Zend/zend_API.c
index 67cfd78546..f456c8b04f 100644
--- a/Zend/zend_API.c
+++ b/Zend/zend_API.c
@@ -592,9 +592,9 @@ ZEND_API int _register_list_destructors(void (*list_destructor)(void *), void (*
/* registers all functions in *library_functions in the function hash */
-int register_functions(function_entry *functions)
+int register_functions(zend_function_entry *functions)
{
- function_entry *ptr = functions;
+ zend_function_entry *ptr = functions;
zend_internal_function internal_function;
int count=0,unload=0;
CLS_FETCH();
@@ -633,9 +633,9 @@ int register_functions(function_entry *functions)
/* count=-1 means erase all functions, otherwise,
* erase the first count functions
*/
-void unregister_functions(function_entry *functions,int count)
+void unregister_functions(zend_function_entry *functions,int count)
{
- function_entry *ptr = functions;
+ zend_function_entry *ptr = functions;
int i=0;
CLS_FETCH();
@@ -753,6 +753,8 @@ zend_class_entry *register_internal_class(zend_class_entry *class_entry)
class_entry->type = ZEND_INTERNAL_CLASS;
class_entry->parent = NULL;
+ class_entry->refcount = (int *) malloc(sizeof(int));
+ *class_entry->refcount = 1;
zend_hash_init(&class_entry->default_properties, 0, NULL, PVAL_PTR_DTOR, 1);
zend_hash_init(&class_entry->function_table, 0, NULL, (void (*)(void *)) destroy_zend_function, 1);