From 8a9e653cc82e85c2d3505d9f5511ed0484ea4ff1 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Mattias=20Engdeg=C3=A5rd?= Date: Tue, 5 Sep 2023 15:39:29 +0200 Subject: [PATCH] ; Add regression test for bug#65726 * test/src/regex-emacs-tests.el (regex-tests-mutual-exclusive-inf-rec): New test. --- test/src/regex-emacs-tests.el | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/test/src/regex-emacs-tests.el b/test/src/regex-emacs-tests.el index c8f161c9b24..c074100e17f 100644 --- a/test/src/regex-emacs-tests.el +++ b/test/src/regex-emacs-tests.el @@ -883,4 +883,8 @@ This evaluates the TESTS test cases from glibc." (should (looking-at "x*\\(=\\|:\\)*")) (should (looking-at "x*=*?")))) +(ert-deftest regex-tests-mutual-exclusive-inf-rec () + ;; Regression test for bug#65726, where this crashed Emacs. + (should (equal (string-match "a*\\(?:c\\|b*\\)*" "a") 0))) + ;;; regex-emacs-tests.el ends here -- 2.39.2