diff -r 1f72226064b8 -r 6fd944c204a9 mercurial/encoding.py --- a/mercurial/encoding.py Fri Sep 12 19:06:11 2014 -0500 +++ b/mercurial/encoding.py Mon Sep 15 13:12:20 2014 -0500 @@ -336,8 +336,8 @@ return s._utf8 try: - if s.decode('utf-8'): - return s + s.decode('utf-8') + return s except UnicodeDecodeError: # surrogate-encode any characters that don't round-trip s2 = s.decode('utf-8', 'ignore').encode('utf-8')