/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to bzrlib/hashcache.py

  • Committer: Matt Nordhoff
  • Date: 2009-04-17 22:24:54 UTC
  • mto: This revision was merged to the branch mainline in revision 4314.
  • Revision ID: mnordhoff@mattnordhoff.com-20090417222454-frskxbd4w812ecnj
Restore Bazaar's customizations to configobj.py:

* Strip trailing whitespace

* Replace "has_key" with "in"

* Don't import the compiler module; it's slow and we don't need it

Other customizations Bazaar previously made have been merged upstream:

* Replace hasattr with getattr

* Don't use the deprecated "message" attribute on exceptions

Show diffs side-by-side

added added

removed removed

Lines of Context:
180
180
                filters = self._filter_provider(path=path, file_id=None)
181
181
            digest = self._really_sha1_file(abspath, filters)
182
182
        elif stat.S_ISLNK(mode):
183
 
            target = osutils.readlink(osutils.safe_unicode(abspath))
184
 
            digest = osutils.sha_string(target.encode('UTF-8'))
 
183
            digest = osutils.sha_string(os.readlink(abspath))
185
184
        else:
186
185
            raise errors.BzrError("file %r: unknown file stat mode: %o"
187
186
                                  % (abspath, mode))