summaryrefslogtreecommitdiff
path: root/ext/recode
diff options
context:
space:
mode:
authorDmitry Stogov <dmitry@php.net>2006-06-15 18:33:09 +0000
committerDmitry Stogov <dmitry@php.net>2006-06-15 18:33:09 +0000
commit1dbaae2795b756a3875c53da00b277f241cc04b8 (patch)
treefd516b57354eb9480e89dcd0503fa990d3cc2068 /ext/recode
parentc3ed91477a011e494559d6f65301ef6b2e38cd22 (diff)
downloadphp-git-1dbaae2795b756a3875c53da00b277f241cc04b8.tar.gz
Added automatic module globals management
Diffstat (limited to 'ext/recode')
-rw-r--r--ext/recode/recode.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/ext/recode/recode.c b/ext/recode/recode.c
index 68494bbb39..cb9ad7d492 100644
--- a/ext/recode/recode.c
+++ b/ext/recode/recode.c
@@ -64,6 +64,7 @@ ZEND_END_MODULE_GLOBALS(recode)
#endif
ZEND_DECLARE_MODULE_GLOBALS(recode);
+static PHP_GINIT_FUNCTION(recode);
/* {{{ module stuff */
static zend_function_entry php_recode_functions[] = {
@@ -83,22 +84,24 @@ zend_module_entry recode_module_entry = {
NULL,
PHP_MINFO(recode),
NO_VERSION_YET,
- STANDARD_MODULE_PROPERTIES
+ PHP_MODULE_GLOBALS(recode),
+ PHP_GINIT(recode),
+ NULL,
+ NULL,
+ STANDARD_MODULE_PROPERTIES_EX
};
#ifdef COMPILE_DL_RECODE
ZEND_GET_MODULE(recode)
#endif
-static void php_recode_init_globals (zend_recode_globals *rg)
+static PHP_GINIT_FUNCTION(recode)
{
- rg->outer = NULL;
+ recode_globals->outer = NULL;
}
PHP_MINIT_FUNCTION(recode)
{
- ZEND_INIT_MODULE_GLOBALS(recode, php_recode_init_globals, NULL);
-
ReSG(outer) = recode_new_outer(false);
if (ReSG(outer) == NULL) {
return FAILURE;