summaryrefslogtreecommitdiff
path: root/ext/intl/grapheme/grapheme_util.c
diff options
context:
space:
mode:
authorChristoph M. Becker <cmbecker69@gmx.de>2016-08-20 03:02:43 +0200
committerChristoph M. Becker <cmbecker69@gmx.de>2016-08-20 03:04:08 +0200
commit078f6742127c65cfbeeac4b5aa3290263367822c (patch)
tree47793892b65a4b1abed03d668683fde337fe01da /ext/intl/grapheme/grapheme_util.c
parentdb1ef5cb00e6bcdd166179fe1293eb628054107b (diff)
parente4a006cd3e17338677ec269a8cdb1354f38e0cad (diff)
downloadphp-git-078f6742127c65cfbeeac4b5aa3290263367822c.tar.gz
Merge branch 'PHP-5.6' into PHP-7.0
Diffstat (limited to 'ext/intl/grapheme/grapheme_util.c')
-rw-r--r--ext/intl/grapheme/grapheme_util.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/intl/grapheme/grapheme_util.c b/ext/intl/grapheme/grapheme_util.c
index b590631c72..020d0d6ef9 100644
--- a/ext/intl/grapheme/grapheme_util.c
+++ b/ext/intl/grapheme/grapheme_util.c
@@ -223,7 +223,7 @@ zend_long grapheme_ascii_check(const unsigned char *day, size_t len)
{
int ret_len = len;
while ( len-- ) {
- if ( *day++ > 0x7f )
+ if ( *day++ > 0x7f || (*day == '\n' && *(day - 1) == '\r') )
return -1;
}