IPS logging: Fix date comparison for last entry

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
This commit is contained in:
Michael Tremer
2019-04-12 17:36:54 +01:00
parent 2eb0c326da
commit d51d3c5b93

View File

@@ -446,12 +446,9 @@ sub processevent
}
$line++;
# Split the date into single chunks.
my ($month, $day, $year) = split('/', $date);
# Check if all data is collected and the date of the event fits the desired date to
# get displayed.
if ($line gt 1 || "$month/$day" eq "$monthstr/$daystr") { &append; }
if ($line gt 1 && $date eq "$monthstr/$daystr") { &append; }
close(LOG);
}