Szia Miklós, On Fri, Sep 26, 2008 at 02:35:59AM +0200, Miklos Vajna wrote: > reduce_heads() can filter "duplicated" parents, where "duplicated" > means: A is duplicated if both A and B are parent candidates and A is > reachable from B. Doing so in builtin-merge makes sense, but not in > builtin-commit, because this breaks git merge --no-commit --no-ff. > Here is a patch that fixes the problem for me. Thanks for the quick response. While your patch does fix the bug I reported, unfortunately it introduces a new one: t7502-commit.sh fails at me with the following: * ok 17: a SIGTERM should break locks * expecting success: git rev-parse second master >expect && test_must_fail git merge second master && git checkout master g && EDITOR=: git commit -a && git cat-file commit HEAD | sed -n -e "s/^parent //p" -e "/^$/q" >actual && test_cmp expect actual Already up-to-date with 1ae92d674ba95768a00bace571f5ef295ff1696b Trying simple merge with 9af21aa779d9e148680be525ce161baa37e4bdec Simple merge did not work, trying automatic merge. Auto-merging g ERROR: Merge conflict in g fatal: merge program failed Automatic merge failed; fix conflicts and then commit the result. Created commit 45a4b2b: Merge branches 'second' and 'master' into second --- expect 2008-09-26 00:59:42.000000000 +0000 +++ actual 2008-09-26 00:59:42.000000000 +0000 @@ -1,2 +1,3 @@ 1ae92d674ba95768a00bace571f5ef295ff1696b +1ae92d674ba95768a00bace571f5ef295ff1696b 9af21aa779d9e148680be525ce161baa37e4bdec * FAIL 18: Hand committing of a redundant merge removes dups git rev-parse second master >expect && test_must_fail git merge second master && git checkout master g && EDITOR=: git commit -a && git cat-file commit HEAD | sed -n -e "s/^parent //p" -e "/^$/q" >actual && test_cmp expect actual * failed 1 among 18 test(s) make: *** [t7502-commit.sh] Error 1 Regards, Gábor -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html