changeset 35988:f87641bf4d23

py3: use bytes instead of str Differential Revision: https://phab.mercurial-scm.org/D2076
author Pulkit Goyal <7895pulkit@gmail.com>
date Wed, 07 Feb 2018 13:47:03 +0530
parents a36d3c8a0e41
children 80e5210df25c
files hgext/mq.py
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/mq.py	Wed Feb 07 13:34:51 2018 +0530
+++ b/hgext/mq.py	Wed Feb 07 13:47:03 2018 +0530
@@ -1272,7 +1272,7 @@
                     if msg == defaultmsg.strip():
                         msg = ''
                     ph.setmessage(msg)
-                    p.write(str(ph))
+                    p.write(bytes(ph))
                     if commitfiles:
                         parent = self.qparents(repo, n)
                         if inclsubs:
@@ -1853,7 +1853,7 @@
                         self.putsubstate2changes(substatestate, c)
                     chunks = patchmod.diff(repo, patchparent,
                                            changes=c, opts=diffopts)
-                    comments = str(ph)
+                    comments = bytes(ph)
                     if comments:
                         patchf.write(comments)
                     for chunk in chunks: