Skip to content

Commit 5070549

Browse files
committed
Sanity check zpp max argument count
This would have prevented 9b4094c. Closes GH-6334.
1 parent 7dc1637 commit 5070549

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

Zend/zend_API.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1311,6 +1311,7 @@ ZEND_API ZEND_COLD void zend_argument_value_error(uint32_t arg_num, const char *
13111311
} while (0)
13121312

13131313
#define ZEND_PARSE_PARAMETERS_END_EX(failure) \
1314+
ZEND_ASSERT(_i == _max_num_args || _max_num_args == (uint32_t) -1); \
13141315
} while (0); \
13151316
if (UNEXPECTED(_error_code != ZPP_ERROR_OK)) { \
13161317
if (!(_flags & ZEND_PARSE_PARAMS_QUIET)) { \

0 commit comments

Comments
 (0)