summaryrefslogtreecommitdiffstats
path: root/perl-install/install_any.pm
diff options
context:
space:
mode:
authorOlivier Blin <oblin@mandriva.org>2005-04-20 14:09:33 +0000
committerOlivier Blin <oblin@mandriva.org>2005-04-20 14:09:33 +0000
commitad2d24b723322d006c8e4b206712cf0113d389a5 (patch)
treee819b14662be3a58494e5970618f5840b2eeb09a /perl-install/install_any.pm
parentd62ac2e8dabb15b5d737340b8dbd5f870cdc5cc2 (diff)
downloaddrakx-ad2d24b723322d006c8e4b206712cf0113d389a5.tar
drakx-ad2d24b723322d006c8e4b206712cf0113d389a5.tar.gz
drakx-ad2d24b723322d006c8e4b206712cf0113d389a5.tar.bz2
drakx-ad2d24b723322d006c8e4b206712cf0113d389a5.tar.xz
drakx-ad2d24b723322d006c8e4b206712cf0113d389a5.zip
do not care about the ISO volume name if it doesn't end in -Disc\d+
Diffstat (limited to 'perl-install/install_any.pm')
-rw-r--r--perl-install/install_any.pm10
1 files changed, 6 insertions, 4 deletions
diff --git a/perl-install/install_any.pm b/perl-install/install_any.pm
index f76386c4b..b8e41a9bd 100644
--- a/perl-install/install_any.pm
+++ b/perl-install/install_any.pm
@@ -118,9 +118,11 @@ sub look_for_ISO_images() {
my $get_iso_ids = sub {
my ($F) = @_;
my ($vol_id, $app_id) = c::get_iso_volume_ids(fileno $F);
- #- the ISO volume names must end in -Disc\d+
- my ($cd_set) = $vol_id =~ /^(.*)-(?:disc|extra|dvd)\d*$/i;
- $cd_set && { cd_set => $cd_set, app_id => $app_id };
+ #- the ISO volume names must end in -Disc\d+ if they are belong (!) to a set
+ my ($cd_set) = $vol_id =~ /^(.*)-disc\d+$/i;
+ #- else use the full volume name as CD set identifier
+ $cd_set ||= $vol_id;
+ { cd_set => $cd_set, app_id => $app_id };
};
sysopen(my $F, $iso_images{loopdev}, 0) or return;
@@ -134,7 +136,7 @@ sub look_for_ISO_images() {
my $iso_dev = devices::set_loop($iso_file) or return;
if (sysopen($F, $iso_dev, 0)) {
my $iso_ids = $get_iso_ids->($F);
- push @{$iso_images{media}}, { file => $iso_file, %$iso_ids } if $iso_ids;
+ push @{$iso_images{media}}, { file => $iso_file, %$iso_ids };
close($F); #- needed to delete loop device
}
devices::del_loop($iso_dev);