Mercurial > hg
changeset 15:6daf7757e92b
Fix network pull of repo files with "%" in their base64 encoding.
author | mpm@selenic.com |
---|---|
date | Wed, 04 May 2005 10:07:10 -0800 |
parents | e0e5c1b9febd |
children | 7eca4cfa8aad |
files | mercurial/hg.py |
diffstat | 1 files changed, 5 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/hg.py Wed May 04 09:33:46 2005 -0800 +++ b/mercurial/hg.py Wed May 04 10:07:10 2005 -0800 @@ -6,6 +6,7 @@ # of the GNU General Public License, incorporated herein by reference. import sys, struct, sha, socket, os, time, base64, re, urllib2, binascii +import urllib from mercurial import byterange from mercurial.transaction import * from mercurial.revlog import * @@ -211,9 +212,11 @@ def opener(base): p = base def o(path, mode="r"): + if p[:7] == "http://": + f = os.path.join(p, urllib.quote(path)) + return httprangereader(f) + f = os.path.join(p, path) - if p[:7] == "http://": - return httprangereader(f) if mode != "r" and os.path.isfile(f): s = os.stat(f)