diff options
author | Thierry Vignaud <tv@mandriva.org> | 2008-10-02 01:03:30 +0000 |
---|---|---|
committer | Thierry Vignaud <tv@mandriva.org> | 2008-10-02 01:03:30 +0000 |
commit | cd1adc73ac19424c188ac9317e939181486a918c (patch) | |
tree | a777a86528c098579b607b8d41ad9da816f1f832 /mdkapplet | |
parent | 8e0bfa5437a84b163cf32a93ab69b8c4d34c00cf (diff) | |
download | mgaonline-cd1adc73ac19424c188ac9317e939181486a918c.tar mgaonline-cd1adc73ac19424c188ac9317e939181486a918c.tar.gz mgaonline-cd1adc73ac19424c188ac9317e939181486a918c.tar.bz2 mgaonline-cd1adc73ac19424c188ac9317e939181486a918c.tar.xz mgaonline-cd1adc73ac19424c188ac9317e939181486a918c.zip |
(upgrade) fix removing media as user
Diffstat (limited to 'mdkapplet')
-rwxr-xr-x | mdkapplet | 14 |
1 files changed, 3 insertions, 11 deletions
@@ -354,18 +354,10 @@ sub upgrade() { logIt(sprintf("locking urpmi database failed: %s"), $err); return; } + undef $_urpmi_lock; - urpm::media::read_config($urpm); - urpm::download::set_cmdline_proxy(); - - my @entries = map { $_->{name} } @{$urpm->{media}}; - my @selected = urpm::media::select_media_by_name($urpm, \@entries, 1); - - if (@selected) { - logIt("removing all existing urpmi media for upgrade"); - urpm::media::remove_media($urpm, \@selected); - urpm::media::write_urpmi_cfg($urpm); - } + logIt("removing all existing urpmi media for upgrade"); + run_program::run('urpmi.removemedia', '-a'); logIt("adding urpmi media for new distribution"); my $product_type = lc($product_id->{type}); $product_type =~ s/\s//g; |