From: Junio C Hamano Date: Wed, 3 May 2006 23:07:02 +0000 (-0700) Subject: read-tree: invalidate cache-tree entry when a new index entry is added. X-Git-Tag: v1.4.0-rc1~45^2~5 X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=c2b9ae43303342a33b2632939f319a3554f3a70c;p=git.git read-tree: invalidate cache-tree entry when a new index entry is added. When doing two-way merge, we failed to invalidate the directory that a new entry is added (we correctly did so for modified and deleted entries). Signed-off-by: Junio C Hamano --- diff --git a/read-tree.c b/read-tree.c index 66c0120f..067fb95e 100644 --- a/read-tree.c +++ b/read-tree.c @@ -446,6 +446,8 @@ static int merged_entry(struct cache_entry *merge, struct cache_entry *old) invalidate_ce_path(old); } } + else + invalidate_ce_path(merge); merge->ce_flags &= ~htons(CE_STAGEMASK); add_cache_entry(merge, ADD_CACHE_OK_TO_ADD); return 1;