my ($line, $l_time, @data);
do {
$line = <$fh>;
- return undef if !defined $line;
+ if (!defined $line) {
+ print STDERR "End of the log file reached.\n";
+ return ();
+ }
chomp $line;
$line =~ s/\A\s+//xms;
($l_time, @data) = split(/\s+/, $line);
} while ($l_time < $self->{begin_time});
- return undef if $l_time > $self->{end_time};
+ if ($l_time > $self->{end_time}) {
+ print STDERR "Requested end time reached.\n";
+ return ();
+ }
return ($l_time, map { hex $_ } @data);
}