From 4cc88690c9c2385573b9a2bd1ac85fe3f174fca3 Mon Sep 17 00:00:00 2001 From: Thierry Vignaud Date: Thu, 15 Mar 2012 12:17:33 +0000 Subject: (cleanrpmsrate) simplify --- pm/MGATools/rpmsrate.pm | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'pm/MGATools/rpmsrate.pm') diff --git a/pm/MGATools/rpmsrate.pm b/pm/MGATools/rpmsrate.pm index 4e7a0e6..16402e8 100644 --- a/pm/MGATools/rpmsrate.pm +++ b/pm/MGATools/rpmsrate.pm @@ -108,9 +108,7 @@ sub cleanrpmsrate { my ($rpmsrate, $output, $norpmsrate, $reprpms, $o_urpm) = @_; $norpmsrate ||= []; - my ($rsrate_ref, $poloc_ref) = preread_rpmsrate($rpmsrate, $norpmsrate); - my @rpmsrate = @$rsrate_ref; - my %potloc = %$poloc_ref; + my ($rsrate_ref, $potloc) = preread_rpmsrate($rpmsrate, $norpmsrate); my (%rpms, $text, %rate, %section, %keyword, %locale, %localized_pkg); my @plain_flags = qw(INSTALL LIVE); @@ -141,13 +139,13 @@ sub cleanrpmsrate { $rpms{$vname} = [ $3, $vname ]; } } else { - check_if_expandable($key, $_, "$dir/$rpm", \%potloc, \%locale, \%localized_pkg, $urpm2, $o_urpm); + check_if_expandable($key, $_, "$dir/$rpm", $potloc, \%locale, \%localized_pkg, $urpm2, $o_urpm); } } } my (%done, @flags, @tree_rate, $prev_level); - foreach (@rpmsrate) { + foreach (@$rsrate_ref) { if (!$_->[0]) { $text .= "$_->[2]$_->[4]\n"; @flags = $_->[2] if $_->[2]; -- cgit v1.2.1