author | Alexis S. L. Carvalho <alexis@cecm.usp.br> |
Mon, 19 Mar 2007 19:07:40 -0300 | |
changeset 4249 | 89075f106414 |
parent 4248 | cc81c512a531 |
child 4250 | ca639faa38a2 |
child 4272 | fe7f38dda34b |
--- a/mercurial/commands.py +++ b/mercurial/commands.py @@ -764,7 +764,11 @@ def debugsetparents(ui, repo, rev1, rev2 if not rev2: rev2 = hex(nullid) - repo.dirstate.setparents(repo.lookup(rev1), repo.lookup(rev2)) + wlock = repo.wlock() + try: + repo.dirstate.setparents(repo.lookup(rev1), repo.lookup(rev2)) + finally: + wlock.release() def debugstate(ui, repo): """show the contents of the current dirstate"""