[PATCH 3 of 7] py3: use bytes() to cast to immutable bytes in changelog.appender.write()
Yuya Nishihara
yuya at tcha.org
Sun Mar 26 07:59:46 EDT 2017
# HG changeset patch
# User Yuya Nishihara <yuya at tcha.org>
# Date 1490513461 -32400
# Sun Mar 26 16:31:01 2017 +0900
# Node ID ea2d8321f3209e5b817353e2e15f7ba6b1b472a5
# Parent 662b30cb4977b4f6fcf56e768ef1c7c5da8e8adc
py3: use bytes() to cast to immutable bytes in changelog.appender.write()
diff --git a/mercurial/changelog.py b/mercurial/changelog.py
--- a/mercurial/changelog.py
+++ b/mercurial/changelog.py
@@ -120,7 +120,7 @@ class appender(object):
return ret
def write(self, s):
- self.data.append(str(s))
+ self.data.append(bytes(s))
self.offset += len(s)
self._end += len(s)
More information about the Mercurial-devel
mailing list