--- a/mercurial/commands.py Fri Jan 15 13:14:49 2016 -0800
+++ b/mercurial/commands.py Fri Jan 15 13:14:49 2016 -0800
@@ -5899,8 +5899,7 @@
fm.end()
return 0
- wlock = repo.wlock()
- try:
+ with repo.wlock():
ms = mergemod.mergestate.read(repo)
if not (ms.active() or repo.dirstate.p2() != nullid):
@@ -6017,9 +6016,6 @@
if not proceed:
return 1
- finally:
- wlock.release()
-
# Nudge users into finishing an unfinished operation
unresolvedf = list(ms.unresolved())
driverresolvedf = list(ms.driverresolved())