diff options
author | Jarkko Hietaniemi <jhi@iki.fi> | 2001-12-13 04:38:19 +0000 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2001-12-13 04:38:19 +0000 |
commit | 332ddc25e33054764b72da8fd0b572ab1c6c6e65 (patch) | |
tree | 11df6fb10d4e8bca0069f7509632e09304816644 /regexec.c | |
parent | c4fbe2471f42249bd57e1c071c99349d2331aea5 (diff) | |
download | perl-332ddc25e33054764b72da8fd0b572ab1c6c6e65.tar.gz |
It could be possible for the case-insensitive
Unicode-aware string comparison to wander off
to the la-la land.
p4raw-id: //depot/perl@13669
Diffstat (limited to 'regexec.c')
-rw-r--r-- | regexec.c | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -971,7 +971,8 @@ S_find_byclass(pTHX_ regexp * prog, regnode *c, char *s, char *strend, char *sta while (s <= e) { if ( utf8_to_uvchr((U8*)s, &len) == c1 && (ln == 1 || - ibcmp_utf8(s, do_utf8, m, UTF, ln)) ) + ibcmp_utf8(s, do_utf8, strend - s, + m, UTF, ln)) ) goto got_it; s += len; } @@ -980,7 +981,8 @@ S_find_byclass(pTHX_ regexp * prog, regnode *c, char *s, char *strend, char *sta UV c = utf8_to_uvchr((U8*)s, &len); if ( (c == c1 || c == c2) && (ln == 1 || - ibcmp_utf8(s, do_utf8, m, UTF, ln)) ) + ibcmp_utf8(s, do_utf8, strend - s, + m, UTF, ln)) ) goto got_it; s += len; } |