~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/lockable_files.py

MergeĀ fromĀ jam-integration.

Show diffs side-by-side

added added

removed removed

Lines of Context:
162
162
        self.put(path, StringIO(a_string.encode('utf-8')))
163
163
 
164
164
    def lock_write(self):
165
 
        mutter("lock write: %s (%s)", self, self._lock_count)
 
165
        # mutter("lock write: %s (%s)", self, self._lock_count)
166
166
        # TODO: Upgrade locking to support using a Transport,
167
167
        # and potentially a remote locking protocol
168
168
        if self._lock_mode:
178
178
            self._set_transaction(transactions.PassThroughTransaction())
179
179
 
180
180
    def lock_read(self):
181
 
        mutter("lock read: %s (%s)", self, self._lock_count)
 
181
        # mutter("lock read: %s (%s)", self, self._lock_count)
182
182
        if self._lock_mode:
183
183
            assert self._lock_mode in ('r', 'w'), \
184
184
                   "invalid lock mode %r" % self._lock_mode
193
193
            self.get_transaction().set_cache_size(5000)
194
194
                        
195
195
    def unlock(self):
196
 
        mutter("unlock: %s (%s)", self, self._lock_count)
 
196
        # mutter("unlock: %s (%s)", self, self._lock_count)
197
197
        if not self._lock_mode:
198
198
            raise LockError('branch %r is not locked' % (self))
199
199