summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2007-09-12 18:29:08 +0000
committerZac Medico <zmedico@gentoo.org>2007-09-12 18:29:08 +0000
commitd36bbaea92bf306b6e17e32d8e03a41eb1b2dcbe (patch)
treea2375ceaef27a01c3d8d0aa91e901e81ba4c67dc
parent16a1cc858b8552a524f29b61e32a47161bcc2d6c (diff)
downloadportage-d36bbaea92bf306b6e17e32d8e03a41eb1b2dcbe.tar.gz
portage-d36bbaea92bf306b6e17e32d8e03a41eb1b2dcbe.tar.bz2
portage-d36bbaea92bf306b6e17e32d8e03a41eb1b2dcbe.zip
Bug #192195 - In dir_get_list(), append a trailing / to the address when
necessary in order to avoid getting a 400 error from the http server. svn path=/main/trunk/; revision=7771
-rw-r--r--pym/portage/getbinpkg.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/pym/portage/getbinpkg.py b/pym/portage/getbinpkg.py
index 752a0fb4c..8225a8242 100644
--- a/pym/portage/getbinpkg.py
+++ b/pym/portage/getbinpkg.py
@@ -298,6 +298,10 @@ def dir_get_list(baseurl,conn=None):
listing = None
if protocol in ["http","https"]:
+ if not address.endswith("/"):
+ # http servers can return a 400 error here
+ # if the address doesn't end with a slash.
+ address += "/"
page,rc,msg = make_http_request(conn,address,params,headers)
if page: