mercurial/changegroup.py
changeset 3762 b9d3e12da485
parent 3706 0d810798acb1
child 3859 8c24b6fd5866
--- a/mercurial/changegroup.py
+++ b/mercurial/changegroup.py
@@ -50,8 +50,8 @@ class nocompress(object):
 bundletypes = {
     "": ("", nocompress),
     "HG10UN": ("HG10UN", nocompress),
-    "HG10BZ": ("HG10", bz2.BZ2Compressor),
-    "HG10GZ": ("HG10GZ", zlib.compressobj),
+    "HG10BZ": ("HG10", lambda: bz2.BZ2Compressor()),
+    "HG10GZ": ("HG10GZ", lambda: zlib.compressobj()),
 }
 
 def writebundle(cg, filename, bundletype):