# HG changeset patch # User Adrian Buehlmann # Date 1351773963 -3600 # Node ID 47fb48060e362d13b282144c83f13442d3f57adc # Parent e0f63ac6fcf326a8d007e40a29905a4e65ee3246 openpath: specify binary mode and use util.posixfile follow-up to 0e2846b2482c diff -r e0f63ac6fcf3 -r 47fb48060e36 mercurial/hg.py --- a/mercurial/hg.py Thu Nov 01 11:37:40 2012 -0200 +++ b/mercurial/hg.py Thu Nov 01 13:46:03 2012 +0100 @@ -92,7 +92,7 @@ def openpath(ui, path): '''open path with open if local, url.open if remote''' if islocal(path): - return open(util.urllocalpath(path)) + return util.posixfile(util.urllocalpath(path), 'rb') else: return url.open(ui, path)