Skip to content

Commit ddb21e4

Browse files
authored
Merge pull request #87 from headius/multiplex_backrefs
Fix multiplex backreferences near end of string in regexp match
2 parents 33f8580 + 5c77c2e commit ddb21e4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/org/joni/ByteCodeMachine.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1442,7 +1442,7 @@ private void opBackRefMulti() {
14421442
int pend = backrefEnd(mem);
14431443

14441444
int n = pend - pstart;
1445-
if (s + n > range) {opFail(); return;}
1445+
if (s + n > range) continue;
14461446

14471447
sprev = s;
14481448
int swork = s;
@@ -1478,7 +1478,7 @@ private void opBackRefMultiIC() {
14781478
int pend = backrefEnd(mem);
14791479

14801480
int n = pend - pstart;
1481-
if (s + n > range) {opFail(); return;}
1481+
if (s + n > range) continue;
14821482

14831483
sprev = s;
14841484

0 commit comments

Comments
 (0)