diff -r b5169e79c31c -r b6673e9bdcf6 mercurial/scmutil.py --- a/mercurial/scmutil.py Sat Jan 26 17:44:07 2019 +0900 +++ b/mercurial/scmutil.py Sat Jan 26 17:51:55 2019 +0900 @@ -248,8 +248,8 @@ and inst.args and inst.args[0] == errno.EPIPE): pass elif getattr(inst, "strerror", None): # common IOError - if getattr(inst, "filename", None): - ui.error(_("abort: %s: %s\n") % ( + if getattr(inst, "filename", None) is not None: + ui.error(_("abort: %s: '%s'\n") % ( encoding.strtolocal(inst.strerror), stringutil.forcebytestr(inst.filename))) else: