mercurial/commands.py
changeset 22381 392ae5cb8d62
parent 22367 c5df4af17110
child 22383 f58b41f6708b
--- a/mercurial/commands.py	Tue Sep 09 17:16:24 2014 -0400
+++ b/mercurial/commands.py	Tue Aug 19 01:13:10 2014 +0200
@@ -454,7 +454,7 @@
     node = scmutil.revsingle(repo, rev).node()
 
     op1, op2 = repo.dirstate.parents()
-    if node not in repo.changelog.commonancestorsheads(op1, node):
+    if not repo.changelog.isancestor(node, op1):
         raise util.Abort(_('cannot backout change that is not an ancestor'))
 
     p1, p2 = repo.changelog.parents(node)