From b8d96756d873dab9685128f491399c535b652abe Mon Sep 17 00:00:00 2001 From: "Heiko Schlittermann (HS12-RIPE)" Date: Wed, 1 Nov 2017 22:38:43 +0100 Subject: [PATCH] exigrep: we need to run with perl 5.8.x The defined-or operator '//' does not exist yet. --- src/src/exigrep.src | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/src/exigrep.src b/src/src/exigrep.src index 9e5c7d8b7..5db01fe08 100644 --- a/src/src/exigrep.src +++ b/src/src/exigrep.src @@ -244,7 +244,8 @@ $pattern = quotemeta $pattern if $literal; # Start a pager if output goes to a terminal if (-t 1 and $use_pager) { - foreach ($ENV{PAGER}//(), 'less', 'more') + # for perl >= v5.10.x: foreach ($ENV{PAGER}//(), 'less', 'more') + foreach (defined $ENV{PAGER} ? $ENV{PAGER} : (), 'less', 'more') { local $ENV{LESS} .= ' --no-init --quit-if-one-screen'; open(my $pager, '|-', $_) or next; -- 2.25.1