mercurial/commands.py
changeset 1754 fdfe89a3962d
parent 1749 d457fec76ab0
child 1755 a8f7791e3680
equal deleted inserted replaced
1753:e6e70450edb9 1754:fdfe89a3962d
   722         try:
   722         try:
   723             # we use a lock here because if we race with commit, we
   723             # we use a lock here because if we race with commit, we
   724             # can end up with extra data in the cloned revlogs that's
   724             # can end up with extra data in the cloned revlogs that's
   725             # not pointed to by changesets, thus causing verify to
   725             # not pointed to by changesets, thus causing verify to
   726             # fail
   726             # fail
   727             l1 = lock.lock(os.path.join(source, ".hg", "lock"))
   727             l1 = other.lock()
   728         except OSError:
   728         except lock.LockException:
   729             copy = False
   729             copy = False
   730 
   730 
   731     if copy:
   731     if copy:
   732         # we lock here to avoid premature writing to the target
   732         # we lock here to avoid premature writing to the target
   733         os.mkdir(os.path.join(dest, ".hg"))
   733         os.mkdir(os.path.join(dest, ".hg"))