From e6b46dc2ff80e78a537155b6d5a556426c90fb59 Mon Sep 17 00:00:00 2001 From: Xinchen Hui Date: Tue, 24 Nov 2015 13:45:16 +0800 Subject: Fixed bug #70960 (ReflectionFunction for array_unique returns wrong number of parameters) --- NEWS | 4 ++++ ext/reflection/tests/bug70960.phpt | 10 ++++++++++ ext/standard/basic_functions.c | 3 ++- 3 files changed, 16 insertions(+), 1 deletion(-) create mode 100644 ext/reflection/tests/bug70960.phpt diff --git a/NEWS b/NEWS index c294e29831..f49ea8ff3e 100644 --- a/NEWS +++ b/NEWS @@ -19,6 +19,10 @@ PHP NEWS - SOAP: . Fixed bug #70900 (SoapClient systematic out of memory error). (Dmitry) +- Standard: + . Fixed bug #70960 (ReflectionFunction for array_unique returns wrong number + of parameters). (Laruence) + 26 Nov 2015, PHP 5.6.16 - Core: diff --git a/ext/reflection/tests/bug70960.phpt b/ext/reflection/tests/bug70960.phpt new file mode 100644 index 0000000000..30885cd1fa --- /dev/null +++ b/ext/reflection/tests/bug70960.phpt @@ -0,0 +1,10 @@ +--TEST-- +Bug #70960 (ReflectionFunction for array_unique returns wrong number of parameters) +--FILE-- +getParameters())); +?> +--EXPECT-- +int(2) diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index 1abe3e60ab..27da28bc2e 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -451,8 +451,9 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_array_change_key_case, 0, 0, 1) ZEND_ARG_INFO(0, case) ZEND_END_ARG_INFO() -ZEND_BEGIN_ARG_INFO(arginfo_array_unique, 0) +ZEND_BEGIN_ARG_INFO_EX(arginfo_array_unique, 0, 0, 1) ZEND_ARG_INFO(0, arg) /* ARRAY_INFO(0, arg, 0) */ + ZEND_ARG_INFO(0, flags) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO_EX(arginfo_array_intersect_key, 0, 0, 2) -- cgit v1.2.1