summaryrefslogtreecommitdiffstats
path: root/urpm/media.pm
diff options
context:
space:
mode:
authorThierry Vignaud <tv@mageia.org>2013-05-24 20:56:26 +0000
committerThierry Vignaud <tv@mageia.org>2013-05-24 20:56:26 +0000
commitf86b22ab4262420b5d958ef4ba90a3a5ddbc19e7 (patch)
tree256051a3fd37f3f8b2e9e68dfdeada26a0190e31 /urpm/media.pm
parent4da170df8c4a910ba7ec60336e86870b16ae1e26 (diff)
downloadurpmi-f86b22ab4262420b5d958ef4ba90a3a5ddbc19e7.tar
urpmi-f86b22ab4262420b5d958ef4ba90a3a5ddbc19e7.tar.gz
urpmi-f86b22ab4262420b5d958ef4ba90a3a5ddbc19e7.tar.bz2
urpmi-f86b22ab4262420b5d958ef4ba90a3a5ddbc19e7.tar.xz
urpmi-f86b22ab4262420b5d958ef4ba90a3a5ddbc19e7.zip
prevent mga#10254 bug to ever happen again
Diffstat (limited to 'urpm/media.pm')
-rw-r--r--urpm/media.pm1
1 files changed, 1 insertions, 0 deletions
diff --git a/urpm/media.pm b/urpm/media.pm
index e3eafdbf..d85567d8 100644
--- a/urpm/media.pm
+++ b/urpm/media.pm
@@ -780,6 +780,7 @@ sub is_media_to_add_by_default {
my ($urpm, $distribconf, $medium, $product_id, $nonfree, $tainted) = @_;
my $add_by_default = !$distribconf->getvalue($medium, 'noauto');
my @media_types = split(':', $distribconf->getvalue($medium, 'media_types'));
+ return $add_by_default if !@media_types;
if ($product_id->{product} eq 'Free') {
if (member('non-free', @media_types)) {
$urpm->{log}(N("ignoring non-free medium `%s'", $medium));