Re: Bug? - Unexpected lock file error

3 messages, 2 authors, 2016-06-15 · open the first message on its own page

Re: Bug? - Unexpected lock file error

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:45:19

Junio C Hamano [off-list ref] writes:
"Eric Raible" [off-list ref] writes:
quoted
If 'empty' has any commits then the merge happens as expected.
I think it is a bug in the git-merge rewritten in C, in "Already
uptodate!" codepath.
Try reverting 18668f5 (builtin-merge: avoid run_command_v_opt() for
recursive and subtree, 2008-08-28).  That patch seems to be seriously
broken.

Re: Bug? - Unexpected lock file error

From: Miklos Vajna <hidden>
Date: 2016-06-15 22:45:19

On Fri, Sep 05, 2008 at 05:09:32PM -0700, Junio C Hamano [off-list ref] wrote:
quoted
I think it is a bug in the git-merge rewritten in C, in "Already
uptodate!" codepath.
I can't reproduce it with master, so I don't think this problem was
introduced by the C rewrite.
Try reverting 18668f5 (builtin-merge: avoid run_command_v_opt() for
recursive and subtree, 2008-08-28).  That patch seems to be seriously
broken.
Yes, that works around the problem. I'll try to send a fix later today.

[PATCH] builtin-merge: release the lockfile in try_merge_strategy()

From: Miklos Vajna <hidden>
Date: 2016-06-15 22:45:19

Once we committed the locked index, we should release the lockfile. In
most cases this is done automatically when the process ends, but this is
not true in this case.

Signed-off-by: Miklos Vajna <redacted>
---

On Sat, Sep 06, 2008 at 04:12:23AM +0200, Miklos Vajna [off-list ref] wrote:
quoted
Try reverting 18668f5 (builtin-merge: avoid run_command_v_opt() for
recursive and subtree, 2008-08-28).  That patch seems to be
seriously broken.
Yes, that works around the problem. I'll try to send a fix later
today.
Here is - I think - the proper prefix.

 builtin-merge.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/builtin-merge.c b/builtin-merge.c
index b857cf6..bb09e6f 100644
--- a/builtin-merge.c
+++ b/builtin-merge.c
@@ -576,6 +576,7 @@ static int try_merge_strategy(const char *strategy, struct commit_list *common,
 				(write_cache(index_fd, active_cache, active_nr) ||
 				 commit_locked_index(lock)))
 			die ("unable to write %s", get_index_file());
+		rollback_lock_file(lock);
 		return clean ? 0 : 1;
 	} else {
 		args = xmalloc((4 + commit_list_count(common) +
-- 
1.6.0.1
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help