From 44b01ef1c159a691aaf7bb61d4d7ade312ebe580 Mon Sep 17 00:00:00 2001 From: etienne Date: Fri, 30 Jul 2004 09:48:24 +0000 Subject: Accelere le chargement de fichiers non standard. --- src/ivymon | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/ivymon b/src/ivymon index 47f1d54..a3e22c3 100755 --- a/src/ivymon +++ b/src/ivymon @@ -1966,6 +1966,7 @@ sub stepsnumber { my $step = 0; my $timefound; + my $lc; # select loading mode # if the 1rst message contains a time field, a dialog window # will be displayed in order to select replay mode or simple @@ -1980,8 +1981,10 @@ sub stepsnumber { } my ($sender, $message) = split(/\s+/, $_, 2); $timefound = 1 if $message =~ /^(\d[\d\.]+\d)\s+.*/; - last; + last if $step; + $lc++; } + $step = int($lc/10) unless $step; seek(IN, 0, 0); return ($step, $timefound); @@ -2182,6 +2185,7 @@ sub loadfileForReplay { chomp; next if /^applications=/ or /^messages_number=/ or /^\s*$/ or /^(marker\d+)$/; ($sender, $time, $message) = split(/\s+/, $_, 3); + $time = int($time); if (defined $replay_max_time) { $replay_max_time = $time if $time > $replay_max_time; } else { -- cgit v1.1