summaryrefslogtreecommitdiff
path: root/regexec.c
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-12-24 06:21:14 (GMT)
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-12-24 06:21:14 (GMT)
commitc80535e50d9ad833d4027dd7bf1a1fc4708bc123 (patch)
tree505d81079bd45792d42ab232437b4d6b63482654 /regexec.c
parentab2a02348b0c361644292906edc1573e4d44b0d9 (diff)
* regexec.c (match_at): follow enclen's change.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26167 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'regexec.c')
-rw-r--r--regexec.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/regexec.c b/regexec.c
index 9fb5ff5..b2f9c9f 100644
--- a/regexec.c
+++ b/regexec.c
@@ -1878,7 +1878,7 @@ match_at(regex_t* reg, const UChar* str, const UChar* end,
if (scv) goto fail;
STACK_PUSH_ALT_WITH_STATE_CHECK(p, s, sprev, mem);
- n = enclen(encode, s);
+ n = enclen(encode, s, end);
DATA_ENSURE(n);
if (ONIGENC_IS_MBC_NEWLINE(encode, s, end)) goto fail;
sprev = s;
@@ -1896,7 +1896,7 @@ match_at(regex_t* reg, const UChar* str, const UChar* end,
if (scv) goto fail;
STACK_PUSH_ALT_WITH_STATE_CHECK(p, s, sprev, mem);
- n = enclen(encode, s);
+ n = enclen(encode, s, end);
if (n > 1) {
DATA_ENSURE(n);
sprev = s;