X-Git-Url: https://git.m6w6.name/?a=blobdiff_plain;ds=sidebyside;f=php_raphf.c;h=1f98145ff756a09e91d3c8cf69150a9f17be5d08;hb=212f2bd0f314846388e4671048bbc951868d325d;hp=f9f354a2cd8503a49f2feaeec80bbc05922aec97;hpb=f706105e1df56286cfeff86c5264270a758fa8f9;p=m6w6%2Fext-raphf diff --git a/php_raphf.c b/php_raphf.c index f9f354a..1f98145 100644 --- a/php_raphf.c +++ b/php_raphf.c @@ -564,7 +564,7 @@ PHP_INI_END() static HashTable *php_persistent_handles_global_hash; -static void php_raphf_globals_init(zend_raphf_globals *raphf_globals) +static PHP_GINIT_FUNCTION(raphf) { raphf_globals->persistent_handle.limit = -1; @@ -577,17 +577,14 @@ static void php_raphf_globals_init(zend_raphf_globals *raphf_globals) } } -static void php_raphf_globals_dtor(zend_raphf_globals *raphf_globals) +static PHP_GSHUTDOWN_FUNCTION(raphf) { zend_hash_destroy(&raphf_globals->persistent_handle.hash); } PHP_MINIT_FUNCTION(raphf) { - ZEND_INIT_MODULE_GLOBALS(raphf, php_raphf_globals_init, - php_raphf_globals_dtor); php_persistent_handles_global_hash = &PHP_RAPHF_G->persistent_handle.hash; - REGISTER_INI_ENTRIES(); return SUCCESS; } @@ -659,7 +656,11 @@ zend_module_entry raphf_module_entry = { NULL, PHP_MINFO(raphf), PHP_RAPHF_VERSION, - STANDARD_MODULE_PROPERTIES + ZEND_MODULE_GLOBALS(raphf), + PHP_GINIT(raphf), + PHP_GSHUTDOWN(raphf), + NULL, + STANDARD_MODULE_PROPERTIES_EX }; /* }}} */