File d3e402928b6eb3327f8f7d59a9edfa622fec557b.patch of Package oniguruma.25626

From d3e402928b6eb3327f8f7d59a9edfa622fec557b Mon Sep 17 00:00:00 2001
From: "K.Kosako" <kosako@sofnec.co.jp>
Date: Tue, 13 Aug 2019 13:37:30 +0900
Subject: [PATCH] fix heap-buffer-overflow

---
 src/regexec.c | 1 +
 1 file changed, 1 insertion(+)

Index: onig-6.7.0/src/regexec.c
===================================================================
--- onig-6.7.0.orig/src/regexec.c
+++ onig-6.7.0/src/regexec.c
@@ -3159,6 +3159,7 @@ str_lower_case_match(OnigEncoding enc, i
     lowlen = ONIGENC_MBC_CASE_FOLD(enc, case_fold_flag, &p, end, lowbuf);
     q = lowbuf;
     while (lowlen > 0) {
+      if (t >= tend)    return 0;
       if (*t++ != *q++) return 0;
       lowlen--;
     }
openSUSE Build Service is sponsored by