From c4520b4af37b9077e683ea9480b40f2964ba6d2d Mon Sep 17 00:00:00 2001 From: Heuzef Date: Fri, 4 Oct 2019 15:46:15 +0200 Subject: [PATCH] Remove useless var --- Check.pm | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/Check.pm b/Check.pm index 41349c6..0447ebd 100644 --- a/Check.pm +++ b/Check.pm @@ -38,7 +38,7 @@ sub action # Start loop foreach my $host ( GetUserHosts(1) ) { - my($fullDur, $incrCnt, $incrAge, $fullSize, $fullRate, $reasonHilite, + my($incrCnt, $incrAge, $reasonHilite, $lastAge, $lastAgeColor, $tempState, $tempReason, $lastXferErrors, $lastXferErrorsColor); my($shortErr); my @Backups = $bpc->BackupInfoRead($host); @@ -57,8 +57,6 @@ sub action $fullCnt++; if ( $fullAge < 0 || $Backups[$i]{startTime} > $fullAge ) { $fullAge = $Backups[$i]{startTime}; - $fullSize = $Backups[$i]{size} / (1024 * 1024); - $fullDur = $Backups[$i]{endTime} - $Backups[$i]{startTime}; } } elsif ( $Backups[$i]{type} eq "incr" ) { $incrCnt++; @@ -88,18 +86,14 @@ sub action } if ( $fullAge < 0 ) { $fullAge = ""; - $fullRate = ""; } else { $fullAge = sprintf("%.1f", (time - $fullAge) / (24 * 3600)); - $fullRate = sprintf("%.2f", - $fullSize / ($fullDur <= 0 ? 1 : $fullDur)); } if ( $incrAge < 0 ) { $incrAge = ""; } else { $incrAge = sprintf("%.1f", (time - $incrAge) / (24 * 3600)); } - $fullSize = sprintf("%.2f", $fullSize / 1024); $incrAge = " " if ( $incrAge eq "" ); # Color for errors $lastXferErrors = $Backups[@Backups-1]{xferErrs} if ( @Backups );