summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2008-02-26 22:42:54 +0000
committerPascal Rigaux <pixel@mandriva.com>2008-02-26 22:42:54 +0000
commita6b13234890201316bc60be9220f0ff40d008981 (patch)
tree88a1426c60365afde9cd4aec99cb7e74f30ab57c
parent41b7546359f0df8adebacf0443f867f67ef20273 (diff)
downloadurpmi-a6b13234890201316bc60be9220f0ff40d008981.tar
urpmi-a6b13234890201316bc60be9220f0ff40d008981.tar.gz
urpmi-a6b13234890201316bc60be9220f0ff40d008981.tar.bz2
urpmi-a6b13234890201316bc60be9220f0ff40d008981.tar.xz
urpmi-a6b13234890201316bc60be9220f0ff40d008981.zip
simplify
-rw-r--r--urpm/removable.pm6
1 files changed, 3 insertions, 3 deletions
diff --git a/urpm/removable.pm b/urpm/removable.pm
index 345ba127..464bd551 100644
--- a/urpm/removable.pm
+++ b/urpm/removable.pm
@@ -91,12 +91,12 @@ sub _mount_and_check_notfound {
try_mounting($urpm, $dir, $removable);
-e $dir or return 2;
- _check_notfound($urpm, $medium_list);
+ _check_notfound($medium_list);
}
#- side-effects: none
sub _check_notfound {
- my ($urpm, $medium_list) = @_;
+ my ($medium_list) = @_;
foreach (values %$medium_list) {
my $dir_ = _filepath($_) or next;
@@ -254,7 +254,7 @@ sub _sort_media {
@l = sort { values(%{$a->{list}}) <=> values(%{$b->{list}}) } @l;
#- check if a removable device is already mounted (and files present).
- if (my ($already_mounted) = grep { !_check_notfound($urpm, $_->{list}) } @l) {
+ if (my ($already_mounted) = grep { !_check_notfound($_->{list}) } @l) {
@l = ($already_mounted, grep { $_ != $already_mounted } @l);
}
}