summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--NEWS1
-rw-r--r--urpm/download.pm6
2 files changed, 6 insertions, 1 deletions
diff --git a/NEWS b/NEWS
index f94181b4..48abe885 100644
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,4 @@
+- remove rsync mirrors when calling aria2
- gurpmi, gurpmi2:
o silence perl warnings (ie remove "use warnings")
diff --git a/urpm/download.pm b/urpm/download.pm
index 1d254bc4..108e829c 100644
--- a/urpm/download.pm
+++ b/urpm/download.pm
@@ -914,7 +914,11 @@ sub _create_metalink_ {
# only use the 8 best mirrors, then we let aria2 choose
require urpm::mirrors;
- my @mirrors = map { _take_n_elem(8, @$_) } urpm::mirrors::list_urls($urpm, $medium, '');
+ my @mirrors = map {
+ # aria2 doesn't handle rsync
+ my @l = grep { urpm::protocol_from_url($_->{url}) ne 'rsync' } @$_;
+ _take_n_elem(16, @l);
+ } urpm::mirrors::list_urls($urpm, $medium, '');
my $metalinkfile = "$urpm->{cachedir}/$options->{media}.metalink";
# Even if not required by metalink spec, this line is needed at top of