~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/osutils.py

  • Committer: John Arbash Meinel
  • Date: 2009-10-08 03:55:30 UTC
  • mto: (4634.52.15 2.0)
  • mto: This revision was merged to the branch mainline in revision 4738.
  • Revision ID: john@arbash-meinel.com-20091008035530-xa6kmr9toz56i62x
Clean up some terminology, catch a double _listdir request, thanks spiv.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1085
1085
        lbit = bit.lower()
1086
1086
        try:
1087
1087
            next_entries = _listdir(current)
1088
 
        except OSError: # enoent
1089
 
            # current doesn't match, so just append the non-existing bits
 
1088
        except OSError: # enoent, eperm, etc
 
1089
            # We can't find this in the filesystem, so just append the
 
1090
            # remaining bits.
1090
1091
            current = pathjoin(current, bit, *list(bit_iter))
1091
1092
            break
1092
 
        for look in _listdir(current):
 
1093
        for look in next_entries:
1093
1094
            if lbit == look.lower():
1094
1095
                current = pathjoin(current, look)
1095
1096
                break