##// END OF EJS Templates
convcmd: pass encoding name as a sysstr...
Augie Fackler -
r36150:6df206ef default
parent child Browse files
Show More
@@ -16,6 +16,7 b' from mercurial import ('
16 encoding,
16 encoding,
17 error,
17 error,
18 hg,
18 hg,
19 pycompat,
19 scmutil,
20 scmutil,
20 util,
21 util,
21 )
22 )
@@ -55,9 +56,10 b" orig_encoding = 'ascii'"
55
56
56 def recode(s):
57 def recode(s):
57 if isinstance(s, unicode):
58 if isinstance(s, unicode):
58 return s.encode(orig_encoding, 'replace')
59 return s.encode(pycompat.sysstr(orig_encoding), 'replace')
59 else:
60 else:
60 return s.decode('utf-8').encode(orig_encoding, 'replace')
61 return s.decode('utf-8').encode(
62 pycompat.sysstr(orig_encoding), 'replace')
61
63
62 def mapbranch(branch, branchmap):
64 def mapbranch(branch, branchmap):
63 '''
65 '''
General Comments 0
You need to be logged in to leave comments. Login now