mirror of
https://github.com/php/php-src.git
synced 2025-08-15 21:48:51 +02:00
Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2: Fix #77827: preg_match does not ignore \r in regex flags
This commit is contained in:
commit
d8b7728b0e
3 changed files with 19 additions and 0 deletions
4
NEWS
4
NEWS
|
@ -14,6 +14,10 @@ PHP NEWS
|
|||
. Fixed bug #77773 (Unbuffered queries leak memory - MySQLi / mysqlnd).
|
||||
(Nikita)
|
||||
|
||||
- PCRE:
|
||||
. Fixed bug #77827 (preg_match does not ignore \r in regex flags). (requinix,
|
||||
cmb)
|
||||
|
||||
- phpdbg:
|
||||
. Fixed bug #76801 (too many open files). (alekitto)
|
||||
. Fixed bug #77800 (phpdbg segfaults on listing some conditional breakpoints).
|
||||
|
|
|
@ -695,6 +695,7 @@ PHPAPI pcre_cache_entry* pcre_get_compiled_regex_cache(zend_string *regex)
|
|||
|
||||
case ' ':
|
||||
case '\n':
|
||||
case '\r':
|
||||
break;
|
||||
|
||||
default:
|
||||
|
|
14
ext/pcre/tests/bug77827.phpt
Normal file
14
ext/pcre/tests/bug77827.phpt
Normal file
|
@ -0,0 +1,14 @@
|
|||
--TEST--
|
||||
Bug #77827 (preg_match does not ignore \r in regex flags)
|
||||
--FILE--
|
||||
<?php
|
||||
var_dump(
|
||||
preg_match("/foo/i\r", 'FOO'),
|
||||
preg_last_error()
|
||||
);
|
||||
?>
|
||||
===DONE===
|
||||
--EXPECT--
|
||||
int(1)
|
||||
int(0)
|
||||
===DONE===
|
Loading…
Add table
Add a link
Reference in a new issue