Skip to contentSkip to conversation

merge-recursive: Do not look at working tree during a virtual ancestor merge

PATCH New Junio C Hamano 1 participant 1 message Jun 15, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 merge-recursive: Do not look at working tree during a virtual ancestor merge

Fix another instance of a recursive merge incorrectly paying attention to the working tree file during a virtual ancestor merge, that resulted in spurious and useless "addinfo_cache failed" error message.

---

* The regression this fixes was seen while I was preparing a merge of maint (soon to become 1.7.6.4) back to master (I cannot write "soon to become 1.7.7" because I want to cook the fix at least for a few days) today.

 merge-recursive.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
merge-recursive.c +1 -1
index 6bbc451..3efc04e 100644
@@ -1627,7 +1627,7 @@ static int merge_content(struct merge_options *o,
 		path_renamed_outside_HEAD = !path2 || !strcmp(path, path2);
 		if (!path_renamed_outside_HEAD) {
 			add_cacheinfo(mfi.mode, mfi.sha, path,
-				      0 /*stage*/, 1 /*refresh*/, 0 /*options*/);
+				      0, (!o->call_depth), 0);
 			return mfi.clean;
 		}
 	} else
Signature · 1 line
1.7.7.rc2.4.g5ec82