archival: tar file modes need to be sysstrs
Differential Revision: https://phab.mercurial-scm.org/D2655
--- a/mercurial/archival.py Sun Mar 04 12:08:19 2018 -0500
+++ b/mercurial/archival.py Sun Mar 04 12:08:37 2018 -0500
@@ -162,9 +162,11 @@
zlib.Z_BEST_COMPRESSION,
fileobj, timestamp=mtime)
self.fileobj = gzfileobj
- return tarfile.TarFile.taropen(name, mode, gzfileobj)
+ return tarfile.TarFile.taropen(
+ name, pycompat.sysstr(mode), gzfileobj)
else:
- return tarfile.open(name, mode + kind, fileobj)
+ return tarfile.open(
+ name, pycompat.sysstr(mode + kind), fileobj)
if isinstance(dest, str):
self.z = taropen('w:', name=dest)