changeset 2206 | c74e91e81f70 |
parent 2201 | f15056b29472 |
child 2281 | 7761597b5da3 |
--- a/mercurial/ui.py +++ b/mercurial/ui.py @@ -242,7 +242,8 @@ class ui(object): def debug(self, *msg): if self.debugflag: self.write(*msg) def edit(self, text, user): - (fd, name) = tempfile.mkstemp(prefix="hg-editor-", suffix=".txt") + (fd, name) = tempfile.mkstemp(prefix="hg-editor-", suffix=".txt", + text=True) try: f = os.fdopen(fd, "w") f.write(text)