From 743b1f6f5ca7ee86348fa0593da2eff03df1a82a Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Tue, 22 Mar 2022 20:12:38 -0700 Subject: grep: Remove recent PCRE2 bug workarounds MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * src/pcresearch.c (Pcompile): Remove recent workaround for PCRE2 bugs; apparently it’s not needed. This reverts back to where things were before today. Suggested by Carlo Arenas in: https://lists.gnu.org/r/grep-devel/2022-03/msg00006.html --- src/pcresearch.c | 7 ------- 1 file changed, 7 deletions(-) (limited to 'src') diff --git a/src/pcresearch.c b/src/pcresearch.c index 6947838a..f332a44f 100644 --- a/src/pcresearch.c +++ b/src/pcresearch.c @@ -157,13 +157,6 @@ Pcompile (char *pattern, idx_t size, reg_syntax_t ignored, bool exact) #endif } -#if defined PCRE2_MATCH_INVALID_UTF && !(10 < PCRE2_MAJOR + (36 <= PCRE2_MINOR)) - /* Work around PCRE2 bug 2642, and another bug reportedly fixed in - PCRE2 commit e0c6029a62db9c2161941ecdf459205382d4d379. */ - if (flags & (PCRE2_UTF | PCRE2_CASELESS)) - flags |= PCRE2_NO_START_OPTIMIZE; -#endif - /* FIXME: Remove this restriction. */ if (rawmemchr (pattern, '\n') != patlim) die (EXIT_TROUBLE, 0, _("the -P option only supports a single pattern")); -- cgit v1.2.1