summaryrefslogtreecommitdiff
path: root/regcomp.c
diff options
context:
space:
mode:
authorHugo van der Sanden <hv@crypt.org>2002-10-21 04:21:54 +0100
committerhv <hv@crypt.org>2002-10-21 01:14:48 +0000
commitc152dc430a400da208b684f936f242f4a89972f4 (patch)
tree8740b8a6b40903791019d5b7f7ce249f20bc5e15 /regcomp.c
parent40a3dda160f7716cf8fb3c9068ec08ae7f6c681e (diff)
downloadperl-c152dc430a400da208b684f936f242f4a89972f4.tar.gz
Re: [perl #18019] regex overoptimization
Message-Id: <200210210221.g9L2LsU32598@crypt.compulink.co.uk> p4raw-id: //depot/perl@18041
Diffstat (limited to 'regcomp.c')
-rw-r--r--regcomp.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/regcomp.c b/regcomp.c
index cc283a6f8c..8afb8abc7f 100644
--- a/regcomp.c
+++ b/regcomp.c
@@ -1306,8 +1306,8 @@ S_study_chunk(pTHX_ RExC_state_t *pRExC_state, regnode **scanp, I32 *deltap, reg
} else {
/* start offset must point into the last copy */
data->last_start_min += minnext * (mincount - 1);
- data->last_start_max += is_inf ? 0 : (maxcount - 1)
- * (minnext + data->pos_delta);
+ data->last_start_max += is_inf ? I32_MAX
+ : (maxcount - 1) * (minnext + data->pos_delta);
}
}
/* It is counted once already... */