chiark / gitweb /
git-debrebase: merge: mergedbreakwaters_anchor: Check consistency
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Sat, 11 Aug 2018 14:39:17 +0000 (15:39 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Sat, 11 Aug 2018 14:40:02 +0000 (15:40 +0100)
Check that the result contains all the other anchors.  This is
ensured by walk, and required of VanillaMerges.

Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
git-debrebase

index 35b75cd..bc725fa 100755 (executable)
@@ -846,6 +846,8 @@ sub mergedbreakwaters_anchor ($) {
        $best_anchor = $panchor
            if !defined $best_anchor
            or is_fast_fwd $best_anchor, $panchor;
+       fail "inconsistent anchors in merged-breakwaters $p->{CommitId}"
+           unless is_fast_fwd $panchor, $best_anchor;
     }
     return $best_anchor;
 }