D2655: archival: tar file modes need to be sysstrs

durin42 (Augie Fackler) phabricator at mercurial-scm.org
Sun Mar 4 13:34:56 EST 2018


This revision was automatically updated to reflect the committed changes.
Closed by commit rHGabf252a1c938: archival: tar file modes need to be sysstrs (authored by durin42, committed by ).

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D2655?vs=6574&id=6583

REVISION DETAIL
  https://phab.mercurial-scm.org/D2655

AFFECTED FILES
  mercurial/archival.py

CHANGE DETAILS

diff --git a/mercurial/archival.py b/mercurial/archival.py
--- a/mercurial/archival.py
+++ b/mercurial/archival.py
@@ -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)



To: durin42, #hg-reviewers, pulkit, indygreg
Cc: mercurial-devel


More information about the Mercurial-devel mailing list