summaryrefslogtreecommitdiff
path: root/check_postgres.pl
diff options
context:
space:
mode:
authorGreg Sabino Mullane2011-06-21 11:25:00 +0000
committerGreg Sabino Mullane2011-06-21 11:25:00 +0000
commit0e83421ac4dac20375784e9e2f7df22cb3fa57e0 (patch)
tree23b3cfd4b20feaa1200ddcde8a2cf6cc36feb4e9 /check_postgres.pl
parent9659e4e9d99569cd7cda4fb835a671509f3609d9 (diff)
Should be warning, not printing, here.
Diffstat (limited to 'check_postgres.pl')
-rwxr-xr-xcheck_postgres.pl3
1 files changed, 2 insertions, 1 deletions
diff --git a/check_postgres.pl b/check_postgres.pl
index 403e7eefa..de2cc694d 100755
--- a/check_postgres.pl
+++ b/check_postgres.pl
@@ -814,7 +814,7 @@ while (my $arg = pop @ARGV) {
if (@badargs) {
warn "Invalid arguments:\n";
for (@badargs) {
- print " $_\n";
+ warn " $_\n";
}
die $USAGE;
}
@@ -1175,6 +1175,7 @@ sub add_response {
$db->{perf} =~ s/^ +//;
$perf .= sprintf '%s%s', length($perf) ? ' ' : '', $db->{perf};
}
+
## Strip trailing semicolons as allowed by the Nagios spec
$perf =~ s/; / /;
$perf =~ s/;$//;