marsadm: safeguard join-resource endless loop

This commit is contained in:
Thomas Schoebel-Theuer 2020-10-26 14:18:00 +01:00 committed by Thomas Schoebel-Theuer
parent e2ef6f4b04
commit c9b7fcf7f9
1 changed files with 1 additions and 1 deletions

View File

@ -3884,8 +3884,8 @@ sub create_res {
}
my $max_retry = 5;
for (;;) {
$max_retry--;
$primary = _get_designated_primary($res, 1);
last if $max_retry-- < 0;
if ($primary && $primary ne $host && $primary ne "(none)") {
# first check whether symlink information appears to be recent enough
last if recent_cluster($cmd, $res, $primary);