equal
deleted
inserted
replaced
1121 fparent1, fparent2 = nullid, newfparent |
1121 fparent1, fparent2 = nullid, newfparent |
1122 else: |
1122 else: |
1123 self.ui.warn(_("warning: can't find ancestor for '%s' " |
1123 self.ui.warn(_("warning: can't find ancestor for '%s' " |
1124 "copied from '%s'!\n") % (fname, cfname)) |
1124 "copied from '%s'!\n") % (fname, cfname)) |
1125 |
1125 |
|
1126 elif fparent1 == nullid: |
|
1127 fparent1, fparent2 = fparent2, nullid |
1126 elif fparent2 != nullid: |
1128 elif fparent2 != nullid: |
1127 # is one parent an ancestor of the other? |
1129 # is one parent an ancestor of the other? |
1128 fparentancestor = flog.ancestor(fparent1, fparent2) |
1130 fparentancestor = flog.ancestor(fparent1, fparent2) |
1129 if fparentancestor == fparent1: |
1131 if fparentancestor == fparent1: |
1130 fparent1, fparent2 = fparent2, nullid |
1132 fparent1, fparent2 = fparent2, nullid |