diff options
author | Rafael Garcia-Suarez <rgarciasuarez@mandriva.org> | 2004-08-03 06:14:33 +0000 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@mandriva.org> | 2004-08-03 06:14:33 +0000 |
commit | 2e284358779f26ce5a7adaa95e7d9f1c5747a490 (patch) | |
tree | 09dc96bae843cad063b3bd2ed90e853a0ae8497e /perl-install/install_any.pm | |
parent | 980e37293295c4003afc2f18a72ca74b2b0c602d (diff) | |
download | drakx-2e284358779f26ce5a7adaa95e7d9f1c5747a490.tar drakx-2e284358779f26ce5a7adaa95e7d9f1c5747a490.tar.gz drakx-2e284358779f26ce5a7adaa95e7d9f1c5747a490.tar.bz2 drakx-2e284358779f26ce5a7adaa95e7d9f1c5747a490.tar.xz drakx-2e284358779f26ce5a7adaa95e7d9f1c5747a490.zip |
A small variable renaming: use $medium for hashes and $medium_name for strings
Diffstat (limited to 'perl-install/install_any.pm')
-rw-r--r-- | perl-install/install_any.pm | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/perl-install/install_any.pm b/perl-install/install_any.pm index 661de041d..0b1ce16b6 100644 --- a/perl-install/install_any.pm +++ b/perl-install/install_any.pm @@ -53,8 +53,8 @@ sub useMedium($) { $asked_medium = $_[0]; } sub changeMedium($$) { - my ($method, $medium) = @_; - log::l("change to medium $medium for method $method (refused by default)"); + my ($method, $medium_name) = @_; + log::l("change to medium $medium_name for method $method (refused by default)"); 0; } sub relGetFile($) { @@ -66,13 +66,13 @@ sub relGetFile($) { $_; } sub askChangeMedium($$) { - my ($method, $medium) = @_; + my ($method, $medium_name) = @_; my $allow; do { - local $::o->{method} = $method = 'cdrom' if $medium =~ /^\d+s$/; #- Suppl CD - eval { $allow = changeMedium($method, $medium) }; + local $::o->{method} = $method = 'cdrom' if $medium_name =~ /^\d+s$/; #- Suppl CD + eval { $allow = changeMedium($method, $medium_name) }; } while $@; #- really it is not allowed to die in changeMedium!!! or install will cores with rpmlib!!! - log::l($allow ? "accepting medium $medium" : "refusing medium $medium"); + log::l($allow ? "accepting medium $medium_name" : "refusing medium $medium_name"); $allow; } @@ -371,7 +371,7 @@ sub setPackages { && $o->ask_yesorno('', N("Do you have a supplementary CD to install?"), 0)) { #- by convention, the media names for suppl. CDs match /^\d+s$/ - my $medium = '1s'; #- supplement 1 + my $medium_name = '1s'; #- supplement 1 local $::isWizard = 0; local $o->{method} = 'cdrom'; (my $cdromdev) = detect_devices::cdroms(); @@ -382,17 +382,17 @@ sub setPackages { if ($o->ask_okcancel('', N("Insert the CD"), 1)) { mountCdrom("/mnt/cdrom", $cdrom); log::l($@) if $@; - useMedium($medium); + useMedium($medium_name); my $supplmedium = pkgs::psUsingHdlist( $o->{prefix}, # /mnt 'cdrom', $o->{packages}, - "hdlist$medium.cz", - $medium, + "hdlist$medium_name.cz", + $medium_name, 'media/main', - "Supplementary CD $medium", + "Supplementary CD $medium_name", 1, # selected - "/mnt/cdrom/media/main/media_info/hdlist$medium.cz", + "/mnt/cdrom/media/main/media_info/hdlist$medium_name.cz", ); if ($supplmedium) { log::l("read suppl hdlist"); @@ -403,7 +403,7 @@ sub setPackages { log::l("no suppl hdlist"); } #- TODO loop if there are several supplementary CDs - # ++$medium; $medium .= "s"; + # ++$medium_name; $medium_name .= "s"; } } else { $suppl_CDs = 0; |