diff options
author | Xinchen Hui <laruence@php.net> | 2015-07-02 12:31:26 +0800 |
---|---|---|
committer | Xinchen Hui <laruence@php.net> | 2015-07-02 12:31:26 +0800 |
commit | 3422fb57c88cdb82868b845e0690569c376f080c (patch) | |
tree | b4f8cddafd9db969f51f615e8972c478af38b0ba /Zend/zend_builtin_functions.c | |
parent | ba91bc36cdcde0ed6f0184df793ce8f332366473 (diff) | |
download | php-git-3422fb57c88cdb82868b845e0690569c376f080c.tar.gz |
Use hash_str directly
Diffstat (limited to 'Zend/zend_builtin_functions.c')
-rw-r--r-- | Zend/zend_builtin_functions.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/Zend/zend_builtin_functions.c b/Zend/zend_builtin_functions.c index fe371ee61a..1a5ba2e5dd 100644 --- a/Zend/zend_builtin_functions.c +++ b/Zend/zend_builtin_functions.c @@ -2689,11 +2689,12 @@ ZEND_FUNCTION(get_extension_funcs) } if (strncasecmp(ZSTR_VAL(extension_name), "zend", sizeof("zend"))) { lcname = zend_string_tolower(extension_name); + module = zend_hash_find_ptr(&module_registry, lcname); + zend_string_release(lcname); } else { - lcname = zend_string_init("core", sizeof("core")-1, 0); + module = zend_hash_str_find_ptr(&module_registry, "core", sizeof("core") - 1); } - module = zend_hash_find_ptr(&module_registry, lcname); - zend_string_release(lcname); + if (!module) { RETURN_FALSE; } |