summaryrefslogtreecommitdiffstats
path: root/urpm.pm
diff options
context:
space:
mode:
authorFrancois Pons <fpons@mandriva.com>2002-02-21 10:54:25 +0000
committerFrancois Pons <fpons@mandriva.com>2002-02-21 10:54:25 +0000
commit4c02fc931782f2d007c2678d2dc857bfd9f59106 (patch)
tree90265f40fb417914ac2b0565e16896994405fa5e /urpm.pm
parent4205726026c17fd914bd93fbc91508a44e15da21 (diff)
downloadurpmi-4c02fc931782f2d007c2678d2dc857bfd9f59106.tar
urpmi-4c02fc931782f2d007c2678d2dc857bfd9f59106.tar.gz
urpmi-4c02fc931782f2d007c2678d2dc857bfd9f59106.tar.bz2
urpmi-4c02fc931782f2d007c2678d2dc857bfd9f59106.tar.xz
urpmi-4c02fc931782f2d007c2678d2dc857bfd9f59106.zip
3.3-13mdk
Diffstat (limited to 'urpm.pm')
-rw-r--r--urpm.pm7
1 files changed, 5 insertions, 2 deletions
diff --git a/urpm.pm b/urpm.pm
index 3ae532de..00608151 100644
--- a/urpm.pm
+++ b/urpm.pm
@@ -1902,9 +1902,14 @@ sub download_source_packages {
#- examine if given medium is already inside a removable device.
my $check_notfound = sub {
my ($id, $dir) = @_;
+ $dir and $urpm->try_mounting($dir);
if (!$dir || -e $dir) {
foreach (values %{$list->[$id]}) {
/^(removable_?[^_:]*|file):\/(.*\/([^\/]*))/ or next;
+ unless ($dir) {
+ $dir = $2;
+ $urpm->try_mounting($dir);
+ }
-r $2 or return 1;
}
} else {
@@ -1922,13 +1927,11 @@ sub download_source_packages {
#- the directory given does not exist or may be accessible
#- by mounting some other. try to figure out these directory and
#- mount everything necessary.
- $urpm->try_mounting($dir);
while ($check_notfound->($id, $dir)) {
$ask_for_medium or $urpm->{fatal}(4, _("medium \"%s\" is not selected", $medium->{name}));
$urpm->try_umounting($dir); system("eject", $device);
$ask_for_medium->($medium->{name}, $medium->{removable}) or
$urpm->{fatal}(4, _("medium \"%s\" is not selected", $medium->{name}));
- $urpm->try_mounting($dir);
}
if (-e $dir) {
my @removable_sources;