marsadm: fix endless wait_cluster

This commit is contained in:
Thomas Schoebel-Theuer 2015-03-09 09:06:28 +01:00
parent ae47fbdcb4
commit 6419b3fb57
1 changed files with 3 additions and 0 deletions

View File

@ -325,6 +325,7 @@ sub wait_cluster {
my $cmd = shift;
my $res = shift || "all";
my $hosts = shift || "*";
my $old_timeout = $timeout;
my $start_time = mars_time();
_trigger();
my $delta = $timeout > 0 ? $timeout : 30;
@ -354,7 +355,9 @@ sub wait_cluster {
}
}
sleep_timeout();
last if $timeout <= 0 && !$unknown_count;
}
$timeout = $old_timeout;
}
##################################################################