diff options
author | Zac Medico <zmedico@gentoo.org> | 2007-09-26 04:00:51 +0000 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2007-09-26 04:00:51 +0000 |
commit | 431c1ce5f51296e36ad96d97aeaf2c949243b150 (patch) | |
tree | 214ed6a74c5bd09b2b33ee74e04379bf722c6a08 /pym | |
parent | 7125d9f64ff6f37482bfcd513175431881e3f856 (diff) | |
download | portage-431c1ce5f51296e36ad96d97aeaf2c949243b150.tar.gz portage-431c1ce5f51296e36ad96d97aeaf2c949243b150.tar.bz2 portage-431c1ce5f51296e36ad96d97aeaf2c949243b150.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. (trunk r7771)
svn path=/main/branches/2.1.2/; revision=7811
Diffstat (limited to 'pym')
-rw-r--r-- | pym/getbinpkg.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/pym/getbinpkg.py b/pym/getbinpkg.py index b11a775e1..71969b006 100644 --- a/pym/getbinpkg.py +++ b/pym/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: |