From d12619349a4c436b930b35973a1b16626b7dab01 Mon Sep 17 00:00:00 2001 From: Alexander Bluhm Date: Thu, 29 Aug 2024 17:15:45 +0200 Subject: [PATCH] Rename statistics file to -when.txt in netlink. --- Netstat.pm | 6 +++--- netlink-html.pl | 2 +- netlink.pl | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Netstat.pm b/Netstat.pm index 6517249..5ff2d01 100644 --- a/Netstat.pm +++ b/Netstat.pm @@ -268,12 +268,12 @@ sub sweep { sub generate_diff_netstat { my ($test) = @_; - my $diff = "$test.stats-diff-netstat.log"; + my $diff = "$test.stats-netstat-diff.txt"; open(my $fh, '>', $diff) or die "Open '$diff' for writing failed: $!"; foreach my $opt (qw(m s)) { - my $before = "$test.stats-before-netstat_-$opt.log"; - my $after = "$test.stats-after-netstat_-$opt.log"; + my $before = "$test.stats-netstat_-$opt-before.txt"; + my $after = "$test.stats-netstat_-$opt-after.txt"; -r $before && -r $after or next; my $parser; diff --git a/netlink-html.pl b/netlink-html.pl index 8b6073b..edeee05 100755 --- a/netlink-html.pl +++ b/netlink-html.pl @@ -644,7 +644,7 @@ sub parse_result_files { $tv->{message} = $message; my $logfile = "$file->{dir}/logs/$test.log"; $tv->{logfile} = $logfile if -f $logfile; - my $stats = "$file->{dir}/logs/$test.stats-diff-netstat.log"; + my $stats = "$file->{dir}/logs/$test.stats-netstat-diff.txt"; $tv->{stats} = $stats if -f $stats; $V{$test}{$hk} = [ @values ]; undef @values; diff --git a/netlink.pl b/netlink.pl index 1063a1c..32173f7 100755 --- a/netlink.pl +++ b/netlink.pl @@ -235,7 +235,7 @@ sub good { generate_diff_netstat($test); my $pass = "PASS"; - my $netstat = "$test.stats-diff-netstat.log"; + my $netstat = "$test.stats-netstat-diff.txt"; open(my $fh, '<', $netstat) or die("Could not open '$netstat'"); while(<$fh>) { @@ -1328,7 +1328,7 @@ sub statistics { my ($test, $when) = @_; foreach my $s (@stats) { my @statcmd = @{$s->{statcmd}}; - my $name = "$test.stats-$when-". join("_", @statcmd). ".log"; + my $name = "$test.stats-". join("_", @statcmd). "-$when.txt"; open(my $fh, '>', $name) or die "Open '$name' for writing failed: $!"; defined(my $pid = fork())