t7812: test PCRE2 whitespace bug
commitc36c27e75cb367e16392cc8fc4fd3f311126ab59
authorRené Scharfe <l.s.r@web.de>
Fri, 8 Apr 2022 16:21:52 +0000 (8 18:21 +0200)
committerJunio C Hamano <gitster@pobox.com>
Mon, 11 Apr 2022 16:42:09 +0000 (11 09:42 -0700)
treec255c0fab8ee1e9ce0b1b34ab7f4245467bfaa53
parentab1f2765f78e75ee51dface57e1071b3b7f42b09
t7812: test PCRE2 whitespace bug

Check if git grep works around the PCRE2 big fixed by their e0c6029
(Fix inifinite loop when a single byte newline is searched in JIT.,
2020-05-29), which affects version 10.35 and earlier.

Searching for leading whitespace also triggers the endless loop.
Set a one-second alarm to abort in case we do get hit by the bug, to
avoid having to wait forever for the test result.

Reported-by: SZEDER Gábor <szeder.dev@gmail.com>
Signed-off-by: René Scharfe <l.s.r@web.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t7812-grep-icase-non-ascii.sh