diff options
author | Dmitry Stogov <dmitry@php.net> | 2012-03-05 12:47:25 +0000 |
---|---|---|
committer | Dmitry Stogov <dmitry@php.net> | 2012-03-05 12:47:25 +0000 |
commit | 56a3f7eca86bda40f5d01d6772d3d70141781cc3 (patch) | |
tree | b1c4b5293bf18719b80bc8d47ccadf2d3c84f534 | |
parent | ad8474c578b6c5f0cfe5035ee02ca1e365af4ca3 (diff) | |
download | php-git-56a3f7eca86bda40f5d01d6772d3d70141781cc3.tar.gz |
Fixed module numbering
-rw-r--r-- | Zend/zend_API.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/Zend/zend_API.c b/Zend/zend_API.c index 1c608a7a30..71feccf9ff 100644 --- a/Zend/zend_API.c +++ b/Zend/zend_API.c @@ -33,7 +33,6 @@ #endif /* these variables are true statics/globals, and have to be mutex'ed on every access */ -static int module_count=0; ZEND_API HashTable module_registry; static zend_module_entry **module_request_startup_handlers; @@ -2381,7 +2380,7 @@ void zend_post_deactivate_modules(TSRMLS_D) /* {{{ */ /* return the next free module number */ int zend_next_free_module(void) /* {{{ */ { - return ++module_count; + return zend_hash_num_elements(&module_registry) + 1; } /* }}} */ |