diff --git a/contrib/analyze-traffic.in b/contrib/analyze-traffic.in index 7fb35e3db..7596be6e4 100644 --- a/contrib/analyze-traffic.in +++ b/contrib/analyze-traffic.in @@ -170,12 +170,14 @@ sub max { my $who; my ($field, $listref) = @_; + ## no critic (Community::Each) while (my ($peer, $statsref) = each %{$listref}) { if ($statsref->{$field} > $x) { $x = $statsref->{$field}; $who = $peer; } } + ## use critic return ($x, $who); } diff --git a/contrib/nnrp.access2readers.conf.in b/contrib/nnrp.access2readers.conf.in index 0d0256b6b..816b43d37 100644 --- a/contrib/nnrp.access2readers.conf.in +++ b/contrib/nnrp.access2readers.conf.in @@ -104,7 +104,7 @@ if (!$debug) { open(PASSWD, ">$passwd") or die "Could not open $passwd: $!\n"; $OUT = \*PASSWD; } -while (my ($u, $p) = each %passwords) { +while (my ($u, $p) = each %passwords) { ## no critic (Community::Each) $p = crypt($p, seedchar() . seedchar()); print $OUT "$u:$p\n"; } diff --git a/scripts/innreport.in b/scripts/innreport.in index ffc7453bf..76e5223bb 100644 --- a/scripts/innreport.in +++ b/scripts/innreport.in @@ -876,7 +876,7 @@ sub ComputeTotal($) { if (defined($cached) && !$DEBUG) { return $cached; } my $total = 0; - while (my ($key, $value) = each %$h) { + while (my ($key, $value) = each %$h) { ## no critic (Community::Each) confess $key unless (defined($value)); $total += $value; } @@ -895,6 +895,7 @@ sub ComputeTotalDouble($) { if (defined($cached) && !$DEBUG) { return $cached; } my $total = 0; + ## no critic (Community::Each) while (my ($key1, $value1) = each %$h) { confess $key1 unless (defined($value1)); while (my ($key2, $value2) = each %$value1) { @@ -902,6 +903,7 @@ sub ComputeTotalDouble($) { $total += $value2; } } + ## use critic if (defined($cached) && $cached != $total) { confess "ComputeTotalDouble mismatch $cached != $total"; }