[PATCH 3 of 5] archival: drop py2.5 taropen workaround
timeless
timeless at mozdev.org
Mon Oct 19 19:33:15 CDT 2015
# HG changeset patch
# User timeless <timeless at mozdev.org>
# Date 1444944158 14400
# Thu Oct 15 17:22:38 2015 -0400
# Node ID fc33b48966cfa28f7abc415cf6ba98a37bbf4e52
# Parent 30001a3db4191ec0eac6c7b3519d7c04cfc57279
archival: drop py2.5 taropen workaround
diff --git a/mercurial/archival.py b/mercurial/archival.py
--- a/mercurial/archival.py
+++ b/mercurial/archival.py
@@ -154,11 +154,7 @@
else:
return tarfile.open(name, mode + kind, fileobj)
- if isinstance(dest, str):
- self.z = taropen(dest, mode='w:')
- else:
- # Python 2.5-2.5.1 have a regression that requires a name arg
- self.z = taropen(name='', mode='w|', fileobj=dest)
+ self.z = taropen(dest, mode='w:')
def addfile(self, name, mode, islink, data):
i = tarfile.TarInfo(name)
More information about the Mercurial-devel
mailing list