requests (Fixes CVE-2010-0397, bug #51288). (Raphael Geissert)
- Fixed 64-bit integer overflow in mhash_keygen_s2k(). (Clément LECIGNE, Stas)
+- Fixed bug #51827 (Bad warning when register_shutdown_function called with
+ wrong num of parameters). (Felipe)
- Fixed bug #51791 (constant() aborts execution when fail to check undefined
constant). (Felipe)
- Fixed bug #51732 (Fileinfo __construct or open does not work with NULL).
--- /dev/null
+--TEST--
+Bug #51827 (Bad warning when register_shutdown_function called with wrong num of parameters)
+--FILE--
+<?php
+
+
+function abc() {
+ var_dump(1);
+}
+
+register_shutdown_function('timE');
+register_shutdown_function('ABC');
+register_shutdown_function('exploDe');
+
+?>
+--EXPECTF--
+int(1)
+
+Warning: explode() expects at least 2 parameters, 0 given in Unknown on line %d
zend_error(E_WARNING, "%s%s%s(): only one varargs specifier (* or +) is permitted",
class_name,
class_name[0] ? "::" : "",
- get_active_function_name(TSRMLS_C));
+ active_function->common.function_name);
}
return FAILURE;
}
zend_error(E_WARNING, "%s%s%s(): bad type specifier while parsing parameters",
class_name,
class_name[0] ? "::" : "",
- get_active_function_name(TSRMLS_C));
+ active_function->common.function_name);
}
return FAILURE;
}
zend_error(E_WARNING, "%s%s%s() expects %s %d parameter%s, %d given",
class_name,
class_name[0] ? "::" : "",
- get_active_function_name(TSRMLS_C),
+ active_function->common.function_name,
min_num_args == max_num_args ? "exactly" : num_args < min_num_args ? "at least" : "at most",
num_args < min_num_args ? min_num_args : max_num_args,
(num_args < min_num_args ? min_num_args : max_num_args) == 1 ? "" : "s",