Permalink
Browse files

fix #58 : access to invalid address by reg->dmin value

  • Loading branch information...
K.Kosako
K.Kosako committed May 23, 2017
1 parent 690313a commit 9690d3ab1f9bcd2db8cbe1fe3ee4a5da606b8814
Showing with 2 additions and 0 deletions.
  1. +2 −0 src/regexec.c
View
@@ -3154,6 +3154,8 @@ forward_search_range(regex_t* reg, const UChar* str, const UChar* end, UChar* s,
}
else {
UChar *q = p + reg->dmin;
if (q >= end) return 0; /* fail */
while (p < q) p += enclen(reg->enc, p);
}
}

0 comments on commit 9690d3a

Please sign in to comment.