Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions UPGRADING.INTERNALS
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,9 @@ PHP 8.6 INTERNALS UPGRADE NOTES
__callStatic zend_function* instead of a CE and a boolean argument.
. The zend_set_hash_symbol() API has been removed.
. Added zend_hash_str_lookup().
. The WRONG_PARAM_COUNT and ZEND_WRONG_PARAM_COUNT() macros have been
removed. Call zend_wrong_param_count(); followed by RETURN_THROWS();
instead.

========================
2. Build system changes
Expand Down
2 changes: 0 additions & 2 deletions Zend/zend_API.h
Original file line number Diff line number Diff line change
Expand Up @@ -523,9 +523,7 @@ ZEND_API const char *zend_get_type_by_const(int type);
#define getThis() (hasThis() ? ZEND_THIS : NULL)
#define ZEND_IS_METHOD_CALL() (EX(func)->common.scope != NULL)

#define WRONG_PARAM_COUNT ZEND_WRONG_PARAM_COUNT()
#define ZEND_NUM_ARGS() EX_NUM_ARGS()
#define ZEND_WRONG_PARAM_COUNT() { zend_wrong_param_count(); return; }

#ifndef ZEND_WIN32
#define DLEXPORT
Expand Down
3 changes: 2 additions & 1 deletion ext/ldap/ldap.c
Original file line number Diff line number Diff line change
Expand Up @@ -980,7 +980,8 @@ PHP_FUNCTION(ldap_connect)

#ifdef HAVE_ORALDAP
if (ZEND_NUM_ARGS() == 3 || ZEND_NUM_ARGS() == 4) {
WRONG_PARAM_COUNT;
zend_wrong_param_count();
RETURN_THROWS();
}

if (zend_parse_parameters(ZEND_NUM_ARGS(), "|s!lssl", &host, &hostlen, &port, &wallet, &walletlen, &walletpasswd, &walletpasswdlen, &authmode) != SUCCESS) {
Expand Down
3 changes: 2 additions & 1 deletion ext/spl/spl_directory.c
Original file line number Diff line number Diff line change
Expand Up @@ -2501,7 +2501,8 @@ PHP_METHOD(SplFileObject, fscanf)
int result = php_sscanf_internal(ZSTR_VAL(intern->u.file.current_line), ZSTR_VAL(format_str), (int)num_varargs, varargs, 0, return_value);

if (SCAN_ERROR_WRONG_PARAM_COUNT == result) {
WRONG_PARAM_COUNT;
zend_wrong_param_count();
RETURN_THROWS();
}
}
/* }}} */
Expand Down
3 changes: 2 additions & 1 deletion ext/standard/file.c
Original file line number Diff line number Diff line change
Expand Up @@ -961,7 +961,8 @@ PHP_FUNCTION(fscanf)
efree(buf);

if (SCAN_ERROR_WRONG_PARAM_COUNT == result) {
WRONG_PARAM_COUNT;
zend_wrong_param_count();
RETURN_THROWS();
}
}
/* }}} */
Expand Down
3 changes: 2 additions & 1 deletion ext/standard/string.c
Original file line number Diff line number Diff line change
Expand Up @@ -5873,7 +5873,8 @@ PHP_FUNCTION(sscanf)
result = php_sscanf_internal(str, format, num_args, args, 0, return_value);

if (SCAN_ERROR_WRONG_PARAM_COUNT == result) {
WRONG_PARAM_COUNT;
zend_wrong_param_count();
RETURN_THROWS();
}
}
/* }}} */
Expand Down