Thanks a lot, Postgres. Now featuring whitespace in psql output that has never been...
authorGreg Sabino Mullane <[email protected]>
Thu, 30 Oct 2014 21:09:10 +0000 (17:09 -0400)
committerGreg Sabino Mullane <[email protected]>
Thu, 30 Oct 2014 21:09:10 +0000 (17:09 -0400)
check_postgres.pl

index a48e36fbabe54dfcaa71bb259c285355813c7db9..634fffefb9c17d47790e2d696385fe10cf0c57a9 100755 (executable)
@@ -2459,7 +2459,7 @@ sub run_command {
                     $lnum++;
                     next;
                 }
-                if ($line =~ /^([\?\w]+)\s+\| (.*)/) {
+                if ($line =~ /^ ?([\?\w]+)\s+\| (.*)/) {
                     $stuff[$lnum]{$1} = $2;
                     $lastval = $1;
                 }
@@ -2488,7 +2488,7 @@ sub run_command {
                     warn "OS:               $^O\n";
                     warn "Action:           $action\n";
                     warn "Calling line:     $cline\n";
-                    warn "Output:           $line\n";
+                    warn "Output:           >>$line<<\n";
                     $args =~ s/ -c (.+)/ -c "$1"/s;
                     warn "Command:          $PSQL $args\n";
                     ## Next to last thing is to see if we can grab the PG version