aboutsummaryrefslogtreecommitdiff
path: root/src/exec.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/exec.rs')
-rw-r--r--src/exec.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/exec.rs b/src/exec.rs
index e75ca08..b9abcdc 100644
--- a/src/exec.rs
+++ b/src/exec.rs
@@ -459,7 +459,7 @@ impl<'c> RegularExpression for ExecNoSync<'c> {
self.cache.value(),
true,
&text[start..],
- text.len(),
+ text.len() - start,
) {
dfa::Result::Match(_) => Some(text.len()),
dfa::Result::NoMatch(_) => None,
@@ -511,7 +511,7 @@ impl<'c> RegularExpression for ExecNoSync<'c> {
self.cache.value(),
true,
&text[start..],
- text.len(),
+ text.len() - start,
) {
dfa::Result::Match(_) => true,
dfa::Result::NoMatch(_) => false,