summaryrefslogtreecommitdiffstats
path: root/urpm
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2008-02-26 19:51:41 +0000
committerPascal Rigaux <pixel@mandriva.com>2008-02-26 19:51:41 +0000
commitdecf6c5f3f26024549b5bcb280e6e5713a21250e (patch)
tree5a2132a43fda05cbbdeaa39863d9d394bd5aa766 /urpm
parent3b2fed1bc06a87b95ce8592198bb1a4864677235 (diff)
downloadurpmi-decf6c5f3f26024549b5bcb280e6e5713a21250e.tar
urpmi-decf6c5f3f26024549b5bcb280e6e5713a21250e.tar.gz
urpmi-decf6c5f3f26024549b5bcb280e6e5713a21250e.tar.bz2
urpmi-decf6c5f3f26024549b5bcb280e6e5713a21250e.tar.xz
urpmi-decf6c5f3f26024549b5bcb280e6e5713a21250e.zip
create _mount_it() out of _examine_removable_medium_()
Diffstat (limited to 'urpm')
-rw-r--r--urpm/removable.pm13
1 files changed, 11 insertions, 2 deletions
diff --git a/urpm/removable.pm b/urpm/removable.pm
index dd00490f..66e696c3 100644
--- a/urpm/removable.pm
+++ b/urpm/removable.pm
@@ -114,8 +114,8 @@ sub _examine_removable_medium {
}
}
-sub _examine_removable_medium_ {
- my ($urpm, $medium, $medium_list, $sources, $device, $o_ask_for_medium) = @_;
+sub _mount_it {
+ my ($urpm, $medium, $medium_list, $device, $o_ask_for_medium) = @_;
my $dir = file_from_local_url($medium->{url});
@@ -131,6 +131,15 @@ sub _examine_removable_medium_ {
|| $o_ask_for_medium->(remove_internal_name($medium->{name}), $medium->{removable})
or $urpm->{fatal}(4, N("medium \"%s\" is not available", $medium->{name}));
}
+}
+
+sub _examine_removable_medium_ {
+ my ($urpm, $medium, $medium_list, $sources, $device, $o_ask_for_medium) = @_;
+
+ _mount_it($urpm, $medium, $medium_list, $device, $o_ask_for_medium);
+
+ my $dir = file_from_local_url($medium->{url});
+
if (-e $dir) {
while (my ($i, $url) = each %$medium_list) {
chomp $url;