context: open files in bytes mode
I'm stunned this open() call has survived this long without the b in
the mode - it seems like it should have been a source of bugs somewhere...
Differential Revision: https://phab.mercurial-scm.org/D5080
--- a/mercurial/context.py Sat Oct 13 09:45:49 2018 -0400
+++ b/mercurial/context.py Sat Oct 13 08:54:31 2018 -0400
@@ -2433,5 +2433,5 @@
def write(self, data, flags, **kwargs):
assert not flags
- with open(self._path, "w") as f:
+ with open(self._path, "wb") as f:
f.write(data)