Skip to content

Commit d3e4029

Browse files
author
K.Kosako
committed
fix heap-buffer-overflow
1 parent fdbbb88 commit d3e4029

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

Diff for: src/regexec.c

+1
Original file line numberDiff line numberDiff line change
@@ -4196,6 +4196,7 @@ str_lower_case_match(OnigEncoding enc, int case_fold_flag,
41964196
lowlen = ONIGENC_MBC_CASE_FOLD(enc, case_fold_flag, &p, end, lowbuf);
41974197
q = lowbuf;
41984198
while (lowlen > 0) {
4199+
if (t >= tend) return 0;
41994200
if (*t++ != *q++) return 0;
42004201
lowlen--;
42014202
}

0 commit comments

Comments
 (0)