From: Nikita Popov Date: Mon, 17 Jun 2019 11:30:15 +0000 (+0200) Subject: Accept null for preg_quote delimiter argument X-Git-Tag: php-7.2.21RC1~48 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=03db04c3aba03fd55c94c9d834a6c151e351cfc5;p=php Accept null for preg_quote delimiter argument Related to bug #78163. --- diff --git a/ext/pcre/php_pcre.c b/ext/pcre/php_pcre.c index 2e827298a9..d7d186540a 100644 --- a/ext/pcre/php_pcre.c +++ b/ext/pcre/php_pcre.c @@ -2419,7 +2419,7 @@ static PHP_FUNCTION(preg_quote) ZEND_PARSE_PARAMETERS_START(1, 2) Z_PARAM_STR(str) Z_PARAM_OPTIONAL - Z_PARAM_STR(delim) + Z_PARAM_STR_EX(delim, 1, 0) ZEND_PARSE_PARAMETERS_END(); /* Nothing to do if we got an empty string */