com php-src: ctor_params of mysqli_fetch_object sho uld use "a": ext/mysqli/mysqli.c ext/mysqli/tes ts/mysqli_fetch_object.phpt
ext/mysqli/tests/mysqli_f etch_object_oo.phpt

From: Date: Mon, 17 Jun 2019 09:46:23 +0000
Subject: com php-src: ctor_params of mysqli_fetch_object sho uld use "a": ext/mysqli/mysqli.c ext/mysqli/tes ts/mysqli_fetch_object.phpt
ext/mysqli/tests/mysqli_f etch_object_oo.phpt
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-106821@lists.php.net to get a copy of this message
Commit: 4c401914f882d0d1e2d95b234367c468dc569964 Author: Nikita Popov <nikita.ppv@gmail.com> Thu, 6 Jun 2019 14:16:25 +0200 Parents: 4d90848d68c4e9a07f8c687f781ae8843d4f64d3 Branches: master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=4c401914f882d0d1e2d95b234367c468dc569964 Log: ctor_params of mysqli_fetch_object should use "a" Changed paths: M ext/mysqli/mysqli.c M ext/mysqli/tests/mysqli_fetch_object.phpt M ext/mysqli/tests/mysqli_fetch_object_oo.phpt Diff: diff --git a/ext/mysqli/mysqli.c b/ext/mysqli/mysqli.c index 61d97b2..9d06591 100644 --- a/ext/mysqli/mysqli.c +++ b/ext/mysqli/mysqli.c @@ -1198,7 +1198,7 @@ void php_mysqli_fetch_into_hash(INTERNAL_FUNCTION_PARAMETERS, int override_flags if (into_object) { zend_string *class_name = NULL; - if (zend_parse_method_parameters(ZEND_NUM_ARGS(), getThis(), "O|Sz", &mysql_result, mysqli_result_class_entry, &class_name, &ctor_params) == FAILURE) { + if (zend_parse_method_parameters(ZEND_NUM_ARGS(), getThis(), "O|Sa", &mysql_result, mysqli_result_class_entry, &class_name, &ctor_params) == FAILURE) { return; } if (class_name == NULL) { diff --git a/ext/mysqli/tests/mysqli_fetch_object.phpt b/ext/mysqli/tests/mysqli_fetch_object.phpt index 262b48d..3230162 100644 --- a/ext/mysqli/tests/mysqli_fetch_object.phpt +++ b/ext/mysqli/tests/mysqli_fetch_object..phpt @@ -142,6 +142,6 @@ NULL NULL [E_WARNING] mysqli_fetch_object(): Couldn't fetch mysqli_result in %s on line %d bool(false) -[0] Argument 3 passed to mysqli_fetch_object() must be of the type array, string given in %s on line %d +[0] mysqli_fetch_object() expects parameter 3 to be array, string given in %s on line %d Fatal error: Class 'this_class_does_not_exist' not found in %s on line %d diff --git a/ext/mysqli/tests/mysqli_fetch_object_oo.phpt b/ext/mysqli/tests/mysqli_fetch_object_oo.phpt index 2688f05..a81cb7f 100644 --- a/ext/mysqli/tests/mysqli_fetch_object_oo.phpt +++ b/ext/mysqli/tests/mysqli_fetch_object_oo.phpt @@ -123,12 +123,12 @@ require_once('skipifconnectfailure.inc'); require_once("clean_table.inc"); ?> --EXPECTF-- -[E_WARNING] mysqli_result::__construct(): invalid object or resource mysql%s -%s on line %d +[E_WARNING] mysqli_result::__construct(): invalid object or resource mysqli + in %s on line %d [E_WARNING] mysqli_result::fetch_object(): Couldn't fetch mysqli_result in %s on line %d -[0] Argument 2 passed to mysqli_result::fetch_object() must be of the type array, object given in %s on line %d -[0] Argument 2 passed to mysqli_result::fetch_object() must be of the type array, object given in %s on line %d -[0] Argument 2 passed to mysqli_result::fetch_object() must be of the type array, null given in %s on line %d +[0] mysqli_result::fetch_object() expects parameter 1 to be string, object given in %s on line %d +[0] mysqli_result::fetch_object() expects at most 2 parameters, 3 given in %s on line %d +[0] mysqli_result::fetch_object() expects parameter 2 to be array, null given in %s on line %d Exception: Too few arguments to function mysqli_fetch_object_construct::__construct(), 1 passed and exactly 2 expected NULL NULL

« previous php.cvs (#106821) next »