From: Nikita Popov Date: Tue, 13 Oct 2020 15:44:56 +0000 (+0200) Subject: Fix incorrect zpp parameter count in mb_substr() / mb_strcut() X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=9b4094c3d74cb7e71dd2dc6ae6673a17575b2a13;p=php Fix incorrect zpp parameter count in mb_substr() / mb_strcut() These functions only accept 4 params. --- diff --git a/ext/mbstring/mbstring.c b/ext/mbstring/mbstring.c index c16b6d8b91..b6395aecdd 100644 --- a/ext/mbstring/mbstring.c +++ b/ext/mbstring/mbstring.c @@ -2130,7 +2130,7 @@ PHP_FUNCTION(mb_substr) zend_bool len_is_null = 1; mbfl_string string, result, *ret; - ZEND_PARSE_PARAMETERS_START(2, 5) + ZEND_PARSE_PARAMETERS_START(2, 4) Z_PARAM_STRING(str, str_len) Z_PARAM_LONG(from) Z_PARAM_OPTIONAL @@ -2194,7 +2194,7 @@ PHP_FUNCTION(mb_strcut) zend_bool len_is_null = 1; mbfl_string string, result, *ret; - ZEND_PARSE_PARAMETERS_START(2, 5) + ZEND_PARSE_PARAMETERS_START(2, 4) Z_PARAM_STRING(string_val, string.len) Z_PARAM_LONG(from) Z_PARAM_OPTIONAL