~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/workingtree_4.py

Fix tree unlock on readonly Format4 trees with dirty hashcache.

Show diffs side-by-side

added added

removed removed

Lines of Context:
415
415
    def unlock(self):
416
416
        """Unlock in format 4 trees needs to write the entire dirstate."""
417
417
        if self._control_files._lock_count == 1:
418
 
            if self._hashcache.needs_write:
419
 
                self._hashcache.write()
 
418
            self._write_hashcache_if_dirty()
420
419
            # eventually we should do signature checking during read locks for
421
420
            # dirstate updates.
422
421
            if self._control_files._lock_mode == 'w':