1
0
mirror of https://github.com/php/php-src.git synced 2026-04-27 01:48:26 +02:00

Fix unregister_tick_function crash

This commit is contained in:
Rasmus Lerdorf
2003-04-02 23:09:39 +00:00
parent ae3616fba8
commit b3ac7b808d
2 changed files with 5 additions and 3 deletions
+2 -2
View File
@@ -11,6 +11,7 @@ Fixed:
array_pad (Rasmus)
str_repeat (Ilia)
setlocale (Rasmus)
unregister_tick_function (Rasmus)
Open:
@@ -20,8 +21,7 @@ Open:
mb_eregi (2)
mb_split
ob_start (3)
unregister_tick_function
xml_parser_create
xml_parser_create (Unable to reproduce - Rasmus)
Notes:
+3 -1
View File
@@ -2672,10 +2672,12 @@ PHP_FUNCTION(unregister_tick_function)
zval **function;
user_tick_function_entry tick_fe;
if (ZEND_NUM_ARGS() != 1 || zend_get_parameters_ex(ZEND_NUM_ARGS(), &function)) {
if (ZEND_NUM_ARGS() != 1 || zend_get_parameters_ex(1, &function)) {
WRONG_PARAM_COUNT;
}
if(!BG(user_tick_functions)) return;
if (Z_TYPE_PP(function) != IS_ARRAY) {
convert_to_string_ex(function);
}