From 8beffbac690338dbe67cd733091c2ed1fbf0bb4b Mon Sep 17 00:00:00 2001 From: Quentin Deslandes Date: Mon, 25 Jul 2022 15:53:12 +0200 Subject: [PATCH] journal: remove unnecessary HAVE_PCRE2 check Since HAVE_PCRE2 checks are performed in pcre2-util.c, there is no need for this extra check in journalctl.c. --- src/journal/journalctl.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/journal/journalctl.c b/src/journal/journalctl.c index 5cc92b5f36d..f7b018f37b0 100644 --- a/src/journal/journalctl.c +++ b/src/journal/journalctl.c @@ -2732,14 +2732,12 @@ int main(int argc, char *argv[]) { finish: pager_close(); -#if HAVE_PCRE2 if (arg_compiled_pattern && r == 0 && n_shown == 0) /* --grep was used, no error was thrown, but the pattern didn't * match anything. Let's mimic grep's behavior here and return * a non-zero exit code, so journalctl --grep can be used * in scripts and such */ r = -ENOENT; -#endif return r < 0 ? EXIT_FAILURE : EXIT_SUCCESS; } -- 2.47.3