From: Nguyễn Thái Ngọc Duy Date: Thu, 20 Aug 2009 13:47:02 +0000 (+0700) Subject: unpack-trees(): carry skip-worktree bit over in merged_entry() X-Git-Tag: v1.7.0-rc0~103^2~17 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=32f54ca31747c47f56abb7ae87a6da0f5b8d97c3;p=git.git unpack-trees(): carry skip-worktree bit over in merged_entry() In this code path, we would remove "old" and replace it with "merge". "old" may have skip-worktree bit, so re-add it to "merge". Signed-off-by: Nguyễn Thái Ngọc Duy Signed-off-by: Junio C Hamano --- diff --git a/unpack-trees.c b/unpack-trees.c index 3eda26359..dc6d74a16 100644 --- a/unpack-trees.c +++ b/unpack-trees.c @@ -680,6 +680,8 @@ static int merged_entry(struct cache_entry *merge, struct cache_entry *old, } else { if (verify_uptodate(old, o)) return -1; + if (ce_skip_worktree(old)) + update |= CE_SKIP_WORKTREE; invalidate_ce_path(old, o); } }