From: Miklos Vajna Date: Sat, 06 Sep 2008 16:29:49 GMT Subject: [PATCH] builtin-merge: release the lockfile in try_merge_strategy() Message-ID: <1220718589-12424-1-git-send-email-vmiklos@frugalware.org> In-Reply-To: <20080906021222.GY16514@genesis.frugalware.org> 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 --- On Sat, Sep 06, 2008 at 04:12:23AM +0200, Miklos Vajna wrote: > > 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