Merge branch 'jc/ll-merge-internal'

"git rerere" can get confused by conflict markers deliberately left
by the inner merge step, because they are indistinguishable from
the real conflict markers left by the outermost merge which are
what the end user and "rerere" need to look at.  This was fixed by
making the conflict markers left by the inner merges a bit longer.

* jc/ll-merge-internal:
  t6036: remove pointless test that expects failure
  ll-merge: use a longer conflict marker for internal merge
  ll-merge: fix typo in comment
This commit is contained in:
Junio C Hamano
2016-05-17 14:38:32 -07:00
3 changed files with 12 additions and 88 deletions

View File

@ -47,7 +47,9 @@ static int ll_binary_merge(const struct ll_merge_driver *drv_unused,
assert(opts);
/*
* The tentative merge result is the or common ancestor for an internal merge.
* The tentative merge result is the common ancestor for an
* internal merge. For the final merge, it is "ours" by
* default but -Xours/-Xtheirs can tweak the choice.
*/
if (opts->virtual_ancestor) {
stolen = orig;
@ -383,8 +385,12 @@ int ll_merge(mmbuffer_t *result_buf,
}
}
driver = find_ll_merge_driver(ll_driver_name);
if (opts->virtual_ancestor && driver->recursive)
driver = find_ll_merge_driver(driver->recursive);
if (opts->virtual_ancestor) {
if (driver->recursive)
driver = find_ll_merge_driver(driver->recursive);
marker_size += 2;
}
return driver->fn(driver, result_buf, path, ancestor, ancestor_label,
ours, our_label, theirs, their_label,
opts, marker_size);