Patchwork D2434: util: use pycompat.bytestr() instead of str()

login
register
mail settings
Submitter phabricator
Date Feb. 26, 2018, 5:39 a.m.
Message ID <03b7996d1135209888ce52b6b486e97f@localhost.localdomain>
Download mbox | patch
Permalink /patch/28372/
State Not Applicable
Headers show

Comments

phabricator - Feb. 26, 2018, 5:39 a.m.
This revision was automatically updated to reflect the committed changes.
Closed by commit rHGd26b0bedfaa4: util: use pycompat.bytestr() instead of str() (authored by durin42, committed by ).

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D2434?vs=6085&id=6092

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

AFFECTED FILES
  mercurial/util.py

CHANGE DETAILS




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

Patch

diff --git a/mercurial/util.py b/mercurial/util.py
--- a/mercurial/util.py
+++ b/mercurial/util.py
@@ -1188,7 +1188,7 @@ 
             return '0'
         if val is True:
             return '1'
-        return str(val)
+        return pycompat.bytestr(val)
     env = dict(encoding.environ)
     if environ:
         env.update((k, py2shell(v)) for k, v in environ.iteritems())