mercurial/localrepo.py
changeset 25629 52e5f68d8363
parent 25625 ce9e231265c1
child 25660 328739ea70c3
equal deleted inserted replaced
25628:9c647f427aef 25629:52e5f68d8363
   951     def transaction(self, desc, report=None):
   951     def transaction(self, desc, report=None):
   952         if (self.ui.configbool('devel', 'all-warnings')
   952         if (self.ui.configbool('devel', 'all-warnings')
   953                 or self.ui.configbool('devel', 'check-locks')):
   953                 or self.ui.configbool('devel', 'check-locks')):
   954             l = self._lockref and self._lockref()
   954             l = self._lockref and self._lockref()
   955             if l is None or not l.held:
   955             if l is None or not l.held:
   956                 scmutil.develwarn(self.ui, 'transaction with no lock')
   956                 self.ui.develwarn('transaction with no lock')
   957         tr = self.currenttransaction()
   957         tr = self.currenttransaction()
   958         if tr is not None:
   958         if tr is not None:
   959             return tr.nest()
   959             return tr.nest()
   960 
   960 
   961         # abort here if the journal already exists
   961         # abort here if the journal already exists
  1256         # acquisition would not cause dead-lock as they would just fail.
  1256         # acquisition would not cause dead-lock as they would just fail.
  1257         if wait and (self.ui.configbool('devel', 'all-warnings')
  1257         if wait and (self.ui.configbool('devel', 'all-warnings')
  1258                      or self.ui.configbool('devel', 'check-locks')):
  1258                      or self.ui.configbool('devel', 'check-locks')):
  1259             l = self._lockref and self._lockref()
  1259             l = self._lockref and self._lockref()
  1260             if l is not None and l.held:
  1260             if l is not None and l.held:
  1261                 scmutil.develwarn(self.ui, '"wlock" acquired after "lock"')
  1261                 self.ui.develwarn('"wlock" acquired after "lock"')
  1262 
  1262 
  1263         def unlock():
  1263         def unlock():
  1264             if self.dirstate.pendingparentchange():
  1264             if self.dirstate.pendingparentchange():
  1265                 self.dirstate.invalidate()
  1265                 self.dirstate.invalidate()
  1266             else:
  1266             else: