diff mercurial/wireprotov1server.py @ 38678:7e4a856a4f05

pullbundle: fix handling of gzip bundlespecs Differential Revision: https://phab.mercurial-scm.org/D3933
author Joerg Sonnenberger <joerg@bec.de>
date Thu, 12 Jul 2018 15:29:03 +0200
parents aac4be30e250
children ad8d8dc9be3f
line wrap: on
line diff
--- a/mercurial/wireprotov1server.py	Wed Jul 11 16:44:33 2018 -0700
+++ b/mercurial/wireprotov1server.py	Thu Jul 12 15:29:03 2018 +0200
@@ -353,7 +353,9 @@
     common_anc = cl.ancestors([cl.rev(rev) for rev in common], inclusive=True)
     compformats = clientcompressionsupport(proto)
     for entry in res:
-        if 'COMPRESSION' in entry and entry['COMPRESSION'] not in compformats:
+        comp = entry.get('COMPRESSION')
+        altcomp = util.compengines._bundlenames.get(comp)
+        if comp and comp not in compformats and altcomp not in compformats:
             continue
         # No test yet for VERSION, since V2 is supported by any client
         # that advertises partial pulls