From df8809650c3808c869d81a30ed306101e75d0d35 Mon Sep 17 00:00:00 2001 From: foobar Date: Fri, 12 Sep 2003 01:31:54 +0000 Subject: - Fixed bug #25504 (pcre_match_all() crashes when passed only 2 parameters) --- ext/pcre/php_pcre.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'ext/pcre/php_pcre.c') diff --git a/ext/pcre/php_pcre.c b/ext/pcre/php_pcre.c index b2c314ba76..e428361062 100644 --- a/ext/pcre/php_pcre.c +++ b/ext/pcre/php_pcre.c @@ -371,7 +371,7 @@ static void php_pcre_match(INTERNAL_FUNCTION_PARAMETERS, int global) char **subpat_names = NULL;/* Array for named subpatterns */ int i; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss|zll", ®ex, ®ex_len, + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, ((global) ? "ssz|ll" : "ss|zll"), ®ex, ®ex_len, &subject, &subject_len, &subpats, &flags, &start_offset) == FAILURE) { RETURN_FALSE; } -- cgit v1.2.1