Skip to content

Commit 040f37f

Browse files
committed
patchdialog: Encode created patches to UTF-8
An alternative approach would be to reuse the encoding of the original files. If we did that, we'd need to handle this better, including adding a confirmation dialog and fallback. In the end, this is sane and probably no one cares that much.
1 parent f98a8da commit 040f37f

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

meld/patchdialog.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,7 @@ def run(self):
118118
filename = self.filediff._get_filename_for_saving(
119119
_("Save Patch"))
120120
if filename:
121+
txt = txt.encode('utf-8')
121122
self.filediff._save_text_to_filename(filename, txt)
122123
break
123124

0 commit comments

Comments
 (0)