branch | stable |
changeset 18501 | a3b2dc1aa909 |
parent 18442 | ecba9b0e7672 |
child 18868 | cafa447a7d3b |
--- a/mercurial/posix.py Tue Jan 29 20:03:51 2013 +0100 +++ b/mercurial/posix.py Tue Jan 29 17:01:41 2013 +0100 @@ -195,6 +195,11 @@ def normcase(path): try: + path.decode('ascii') # throw exception for non-ASCII character + return path.lower() + except UnicodeDecodeError: + pass + try: u = path.decode('utf-8') except UnicodeDecodeError: # percent-encode any characters that don't round-trip