git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] merge-tree: fix typo in "both changed identically"
@ 2013-04-27 13:03 John Keeping
  2013-04-27 13:23 ` René Scharfe
  2013-04-27 13:40 ` [PATCH v2] " John Keeping
  0 siblings, 2 replies; 5+ messages in thread
From: John Keeping @ 2013-04-27 13:03 UTC (permalink / raw)
  To: git; +Cc: René Scharfe, Junio C Hamano, John Keeping

Commit aacecc3 (merge-tree: don't print entries that match "local" -
2013-04-07) had a typo causing the "same in both" check to be incorrect
and check if both the base and "their" versions are empty instead of
checking that both the "our" and "their" versions are empty.  Fix this.

Reported-by: René Scharfe <rene.scharfe@lsrfire.ath.cx>
Signed-off-by: John Keeping <john@keeping.me.uk>
---
 builtin/merge-tree.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/builtin/merge-tree.c b/builtin/merge-tree.c
index ed25d81..ec49917 100644
--- a/builtin/merge-tree.c
+++ b/builtin/merge-tree.c
@@ -302,7 +302,7 @@ static void unresolved(const struct traverse_info *info, struct name_entry n[3])
 static int threeway_callback(int n, unsigned long mask, unsigned long dirmask, struct name_entry *entry, struct traverse_info *info)
 {
 	/* Same in both? */
-	if (same_entry(entry+1, entry+2) || both_empty(entry+0, entry+2)) {
+	if (same_entry(entry+1, entry+2) || both_empty(entry+1, entry+2)) {
 		/* Modified, added or removed identically */
 		resolve(info, NULL, entry+1);
 		return mask;
-- 
1.8.2.1.715.gb260f47

^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2013-04-28 18:54 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-04-27 13:03 [PATCH] merge-tree: fix typo in "both changed identically" John Keeping
2013-04-27 13:23 ` René Scharfe
2013-04-27 13:38   ` John Keeping
2013-04-27 13:40 ` [PATCH v2] " John Keeping
2013-04-28 18:54   ` Junio C Hamano

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).