summaryrefslogtreecommitdiff
path: root/check_postgres.pl
diff options
context:
space:
mode:
authorGreg Sabino Mullane2009-02-09 16:28:53 +0000
committerGreg Sabino Mullane2009-02-09 16:28:53 +0000
commit2d0473d0eac2d7489e5c4aa1108c87124873ffcf (patch)
tree7373b855385ba66314f4fd9ea3ac3cd47c4b35ee /check_postgres.pl
parent4bf3dca891fdb7e2dd1defb7cf9a21f61f76ba7c (diff)
Better logic at finding groups of connections.
Diffstat (limited to 'check_postgres.pl')
-rwxr-xr-xcheck_postgres.pl6
1 files changed, 4 insertions, 2 deletions
diff --git a/check_postgres.pl b/check_postgres.pl
index 47e42ed50..598aa9869 100755
--- a/check_postgres.pl
+++ b/check_postgres.pl
@@ -975,6 +975,8 @@ sub run_command {
$group{$vname} = $conn->{$vname};
}
+ last GROUP if ! $foundgroup and @target;
+
$gbin++;
## Now break the newly created group into individual targets
@@ -997,11 +999,11 @@ sub run_command {
push @target, \%temptarget;
$tbin++;
- redo;
+ redo TARGET;
} ## end TARGET
last GROUP if ! $foundgroup;
- redo;
+ redo GROUP;
} ## end GROUP
if (! @target) {