# HG changeset patch # User Mads Kiilerich # Date 1396905471 -7200 # Node ID 298c9f346dde7300f99d3806d6b1631dd8d4f71f # Parent 6ae0c41e4b525d9b331db2c089cce660de01da61 commit: use revlog.commonancestors instead of .ancestor This do probably not make any real difference but is slightly more correct and we would like to get rid of flog.ancestor. diff -r 6ae0c41e4b52 -r 298c9f346dde mercurial/localrepo.py --- a/mercurial/localrepo.py Mon Apr 07 23:17:51 2014 +0200 +++ b/mercurial/localrepo.py Mon Apr 07 23:17:51 2014 +0200 @@ -1154,10 +1154,10 @@ fparent1, fparent2 = fparent2, nullid elif fparent2 != nullid: # is one parent an ancestor of the other? - fparentancestor = flog.ancestor(fparent1, fparent2) - if fparentancestor == fparent1: + fparentancestors = flog.commonancestors(fparent1, fparent2) + if fparent1 in fparentancestors: fparent1, fparent2 = fparent2, nullid - elif fparentancestor == fparent2: + elif fparent2 in fparentancestors: fparent2 = nullid # is the file changed?