From: Greg Sabino Mullane Date: Wed, 7 Apr 2010 18:46:14 +0000 (-0400) Subject: Fix some old code paths so the txn_idle tests work again. X-Git-Tag: 2.15.1~44 X-Git-Url: http://waps.l3s.uni-hannover.de/gitweb/?a=commitdiff_plain;h=89746d01dfca745916150b35388da582b95b7774;p=check_postgres.git Fix some old code paths so the txn_idle tests work again. --- diff --git a/check_postgres.pl b/check_postgres.pl index f331770da..eafdea1aa 100755 --- a/check_postgres.pl +++ b/check_postgres.pl @@ -6611,12 +6611,12 @@ sub check_txn_idle { $max = $current if $current > $max; } if ($MRTG) { - $stats{$db->{dbname}} = $max; + $stats{$db->{dbname}} = $max < 0 ? 0 : $max; next; } $db->{perf} .= msg('maxtime', $max); if ($max < 0) { - add_unknown 'T-EXCLUDE-DB'; + add_unknown msg('txnidle-none'); next; } @@ -6710,7 +6710,6 @@ WHERE xact_start IS NOT NULL $USERWHERECLAUSE ## Use of skip_item means we may have no matches if ($maxdb eq '?') { if ($USERWHERECLAUSE) { ## needed? - #add_unknown 'T-EXCLUDE-DB'; add_unknown msg('tttt-nomatch'); } else {