~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/dirstate.py

  • Committer: Martin Packman
  • Date: 2012-01-05 11:16:45 UTC
  • mto: This revision was merged to the branch mainline in revision 6429.
  • Revision ID: martin.packman@canonical.com-20120105111645-dkj4c6geuh38ir0n
Expect normalised _fs_enc in dirstate check for avoiding reencoding

Show diffs side-by-side

added added

removed removed

Lines of Context:
1924
1924
            # paths are produced by UnicodeDirReader on purpose.
1925
1925
            abspath = abspath.encode(fs_encoding)
1926
1926
        target = os.readlink(abspath)
1927
 
        if fs_encoding not in ('UTF-8', 'US-ASCII', 'ANSI_X3.4-1968'):
 
1927
        if fs_encoding not in ('utf-8', 'ascii'):
1928
1928
            # Change encoding if needed
1929
1929
            target = target.decode(fs_encoding).encode('UTF-8')
1930
1930
        return target