Skip to content

Commit e3409de

Browse files
committed
Support Perl 5.8 which doesn't have // yet
Patch by Ed Sabol, close bucardo#126.
1 parent 07c93ca commit e3409de

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

check_postgres.pl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8101,8 +8101,8 @@ sub check_txn_idle {
81018101
next if skip_item($r->{datname});
81028102

81038103
## We do a lot of filtering based on the current_query or state in 9.2+
8104-
my $cq = $r->{query} // $r->{current_query};
8105-
my $st = $r->{state} // '';
8104+
my $cq = defined($r->{query}) ? $r->{query} : $r->{current_query};
8105+
my $st = defined($r->{state}) ? $r->{state} : '';
81068106

81078107
## Return unknown if we cannot see because we are a non-superuser
81088108
if ($cq =~ /insufficient/) {

0 commit comments

Comments
 (0)