else
{
# Auto detect log format for proper parsing
- my $fmt = autodetect_format($f);
+ my $fmt = autodetect_format($f, $file_size{$f});
# Set regex to parse the log file
$fmt = set_parser_regex($fmt);
sub autodetect_format
{
- my $file = shift;
- my $totalsize = shift;
+ my ($file, $totalsize) = @_;
# a file must be passed
return if (!$file);
}
else
{
- &logmsg('DEBUG', "Can not autodetected log format from $file, using default");
+ &logmsg('DEBUG', "Can not autodetect log format from $file, using default");
return 'default';
}
sub get_log_file
{
- my $logf = shift;
- my $totalsize = shift;
- my $sample_only = shift;
+ my ($logf, $totalsize, $sample_only) = @_;
my $lfile = undef;