diff options
author | Stephen Hemminger <shemminger@vyatta.com> | 2010-02-22 18:17:20 -0500 |
---|---|---|
committer | Michal Marek <mmarek@suse.cz> | 2010-03-07 15:39:33 -0500 |
commit | 9c49fd307a6cb2d3255f9441bce5b7cb08dff79e (patch) | |
tree | 7ef6dd837c79095d7f282b439b3cb6a5d5732460 | |
parent | 86d08e569f63a71a2d259507e335beea32b4d2aa (diff) |
profile2linkerlist: fix perl warnings
Turn on strict checking.
Simplify code by using "unless" statement.
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Acked-by: WANG Cong <amwang@redhat.com>
Cc: Michal Marek <mmarek@suse.cz>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Michal Marek <mmarek@suse.cz>
-rw-r--r-- | scripts/profile2linkerlist.pl | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/scripts/profile2linkerlist.pl b/scripts/profile2linkerlist.pl index cb4260ebdb91..6943fa7cc95b 100644 --- a/scripts/profile2linkerlist.pl +++ b/scripts/profile2linkerlist.pl | |||
@@ -7,15 +7,13 @@ | |||
7 | # usage: | 7 | # usage: |
8 | # readprofile | sort -rn | perl profile2linkerlist.pl > functionlist | 8 | # readprofile | sort -rn | perl profile2linkerlist.pl > functionlist |
9 | # | 9 | # |
10 | use strict; | ||
10 | 11 | ||
11 | while (<>) { | 12 | while (<>) { |
12 | my $line = $_; | 13 | my $line = $_; |
13 | 14 | ||
14 | $_ =~ /\W*[0-9]+\W*([a-zA-Z\_0-9]+)\W*[0-9]+/; | 15 | $_ =~ /\W*[0-9]+\W*([a-zA-Z\_0-9]+)\W*[0-9]+/; |
15 | 16 | ||
16 | if ( ($line =~ /unknown/) || ($line =~ /total/)) { | 17 | print "*(.text.$1)\n" |
17 | 18 | unless ($line =~ /unknown/) || ($line =~ /total/); | |
18 | } else { | ||
19 | print "*(.text.$1)\n"; | ||
20 | } | ||
21 | } | 19 | } |