aparently someone never heard of rstrip...
authorBrian Harring <ferringb@gentoo.org>
Sat, 4 Feb 2006 12:32:29 +0000 (12:32 -0000)
committerBrian Harring <ferringb@gentoo.org>
Sat, 4 Feb 2006 12:32:29 +0000 (12:32 -0000)
svn path=/main/trunk/; revision=2660

pym/portage.py

index 9ab0a0891faea6da402e488a420047e070cc2b34..4bd7a65ac99c9ed689fc438cbec6b6b5050606c7 100644 (file)
@@ -1718,12 +1718,7 @@ def fetch(myuris, mysettings, listonly=0, fetchonly=0, locks_in_subdir=".locks",
                pass
        else:
                if try_mirrors:
-                       for x in mysettings["GENTOO_MIRRORS"].split():
-                               if x:
-                                       if x[-1] == '/':
-                                               mymirrors += [x[:-1]]
-                                       else:
-                                               mymirrors += [x]
+                       mymirrors += [x.rstrip("/") for x in mysettings["GENTOO_MIRRORS"].split() if x]
 
        mydigests = {}
        digestfn  = mysettings["FILESDIR"]+"/digest-"+mysettings["PF"]