##// END OF EJS Templates
rebase: cover restorestatus() by lock to prevent it from being updated...
Sushil khanchi -
r39152:ffb34ee6 default
parent child Browse files
Show More
@@ -837,18 +837,17 b' def rebase(ui, repo, **opts):'
837 return _dryrunrebase(ui, repo, action, opts)
837 return _dryrunrebase(ui, repo, action, opts)
838 elif action == 'stop':
838 elif action == 'stop':
839 rbsrt = rebaseruntime(repo, ui)
839 rbsrt = rebaseruntime(repo, ui)
840 rbsrt.restorestatus()
841
842 if rbsrt.collapsef:
843 raise error.Abort(_("cannot stop in --collapse session"))
844 allowunstable = obsolete.isenabled(repo, obsolete.allowunstableopt)
845 if not (rbsrt.keepf or allowunstable):
846 raise error.Abort(_("cannot remove original changesets with"
847 " unrebased descendants"),
848 hint=_('either enable obsmarkers to allow unstable '
849 'revisions or use --keep to keep original '
850 'changesets'))
851 with repo.wlock(), repo.lock():
840 with repo.wlock(), repo.lock():
841 rbsrt.restorestatus()
842 if rbsrt.collapsef:
843 raise error.Abort(_("cannot stop in --collapse session"))
844 allowunstable = obsolete.isenabled(repo, obsolete.allowunstableopt)
845 if not (rbsrt.keepf or allowunstable):
846 raise error.Abort(_("cannot remove original changesets with"
847 " unrebased descendants"),
848 hint=_('either enable obsmarkers to allow unstable '
849 'revisions or use --keep to keep original '
850 'changesets'))
852 if needupdate(repo, rbsrt.state):
851 if needupdate(repo, rbsrt.state):
853 # update to the current working revision
852 # update to the current working revision
854 # to clear interrupted merge
853 # to clear interrupted merge
General Comments 0
You need to be logged in to leave comments. Login now