Mercurial > hg
changeset 48786:f20feb496d3c
filemerge: use leverage `util.readfile()` in `_maketempfiles()`
Differential Revision: https://phab.mercurial-scm.org/D12191
author | Martin von Zweigbergk <martinvonz@google.com> |
---|---|
date | Mon, 14 Feb 2022 22:11:50 -0800 |
parents | b53f2f5a18de |
children | 69000dc0dced |
files | mercurial/filemerge.py |
diffstat | 1 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/filemerge.py Mon Feb 14 22:04:50 2022 -0800 +++ b/mercurial/filemerge.py Mon Feb 14 22:11:50 2022 -0800 @@ -944,8 +944,8 @@ d = localpath if localpath is not None: f, d = maketempfrompath(b"local", d) - with open(localpath, b'rb') as src: - f.write(src.read()) + data = util.readfile(localpath) + f.write(data) f.close() try: