From 859c208835be5649277460b2e0f076f42088f741 Mon Sep 17 00:00:00 2001 From: Thomas Schoebel-Theuer Date: Sun, 2 Aug 2020 12:46:27 +0200 Subject: [PATCH] marsadm: silence warnings --- userspace/marsadm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/userspace/marsadm b/userspace/marsadm index b7984fb5..61092ff8 100755 --- a/userspace/marsadm +++ b/userspace/marsadm @@ -1422,7 +1422,7 @@ sub get_link_stamp { sub is_recent { my ($stamp, $wind) = @_; - return 0 unless $stamp; + return 0 unless ($stamp && $stamp =~ m/^\s*[0-9.]/); $wind = $window * 2 unless $wind; return 1 if $stamp + $wind >= mars_time(); return 0; @@ -1660,7 +1660,7 @@ sub get_alive_links { return %peers unless %peers; my %links; foreach my $peer (keys(%peers)) { - my $val = get_alive_link($alive, $peer, 1); + my $val = get_alive_link($alive, $peer, 2); # When required and possible, get the _remote_ timestamp # when the link tree was read _remotely_. if ($use_remote_stamp) {