From f8426736c6380bb6778b841c39f79c5fa3ddcfc9 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Tue, 13 Oct 2020 17:53:49 +0200 Subject: [PATCH] Sanity check zpp max argument count --- Zend/zend_API.h | 1 + 1 file changed, 1 insertion(+) diff --git a/Zend/zend_API.h b/Zend/zend_API.h index 0b6808b678836..301b0400041e5 100644 --- a/Zend/zend_API.h +++ b/Zend/zend_API.h @@ -1311,6 +1311,7 @@ ZEND_API ZEND_COLD void zend_argument_value_error(uint32_t arg_num, const char * } while (0) #define ZEND_PARSE_PARAMETERS_END_EX(failure) \ + ZEND_ASSERT(_i == _max_num_args || _max_num_args == (uint32_t) -1); \ } while (0); \ if (UNEXPECTED(_error_code != ZPP_ERROR_OK)) { \ if (!(_flags & ZEND_PARSE_PARAMS_QUIET)) { \