Should be warning, not printing, here.
authorGreg Sabino Mullane <[email protected]>
Tue, 21 Jun 2011 11:25:00 +0000 (07:25 -0400)
committerGreg Sabino Mullane <[email protected]>
Tue, 21 Jun 2011 11:25:00 +0000 (07:25 -0400)
check_postgres.pl

index 403e7eefaa47eba555754a9274fbcf54e3a58ee5..de2cc694df0cc36069b6d332a23d29cbfdec9ee4 100755 (executable)
@@ -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/;$//;