Mercurial > public > mercurial-scm > hg-stable
diff mercurial/httprepo.py @ 14060:aaa9a5989405
bundle: more comments about the different header types, remove useless if
author | Benoit Boissinot <benoit.boissinot@ens-lyon.org> |
---|---|
date | Sat, 30 Apr 2011 14:22:03 +0200 |
parents | d16894e29f91 |
children | 924c82157d46 |
line wrap: on
line diff
--- a/mercurial/httprepo.py Sat Apr 30 15:30:51 2011 +0200 +++ b/mercurial/httprepo.py Sat Apr 30 14:22:03 2011 +0200 @@ -147,19 +147,18 @@ # have to stream bundle to a temp file because we do not have # http 1.1 chunked transfer. - type = "" types = self.capable('unbundle') - # servers older than d1b16a746db6 will send 'unbundle' as a - # boolean capability try: types = types.split(',') except AttributeError: + # servers older than d1b16a746db6 will send 'unbundle' as a + # boolean capability. They only support headerless/uncompressed + # bundles. types = [""] - if types: - for x in types: - if x in changegroup.bundletypes: - type = x - break + for x in types: + if x in changegroup.bundletypes: + type = x + break tempname = changegroup.writebundle(cg, None, type) fp = url.httpsendfile(self.ui, tempname, "rb")