소스 검색

tracing/fastboot: fix perlcritic warning

Impact: cleanup

Fix the following warning from the perl syntax checking tool perlcritic.
This tool is a lint like tool that checks for perl best practices.

Loop iterator is not lexical at line 113, column 1.
See page 108 of PBP.  (Severity: 5)

Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Stephen Hemminger 16 년 전
부모
커밋
68f96c0c88
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      scripts/bootgraph.pl

+ 2 - 2
scripts/bootgraph.pl

@@ -109,8 +109,8 @@ my $stylecounter = 0;
 my %rows;
 my %rows;
 my $rowscount = 1;
 my $rowscount = 1;
 my @initcalls = sort { $start{$a} <=> $start{$b} } keys(%start);
 my @initcalls = sort { $start{$a} <=> $start{$b} } keys(%start);
-my $key;
-foreach $key (@initcalls) {
+
+foreach my $key (@initcalls) {
 	my $duration = $end{$key} - $start{$key};
 	my $duration = $end{$key} - $start{$key};
 
 
 	if ($duration >= $threshold) {
 	if ($duration >= $threshold) {