Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2008-05-04 04:24:28 +0400
committerJunio C Hamano <gitster@pobox.com>2008-05-05 04:41:27 +0400
commit050288d52dc5dc3f6c7716007c1069dd9f59feb7 (patch)
tree16d133049b6c9dfaf36e0125e01ff792270bbe21 /read-cache.c
parent451244d724f921eca9ffaf526d45c825f7c6f4eb (diff)
is_racy_timestamp(): do not check timestamp for gitlinks
Because we do not even check the timestamp to determie if a gitlink is up to date or not, triggering the racy-timestamp check for gitlinks does not make sense. This fixes the recently added test in t7506. Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'read-cache.c')
-rw-r--r--read-cache.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/read-cache.c b/read-cache.c
index a92b25b59b..9ee125597e 100644
--- a/read-cache.c
+++ b/read-cache.c
@@ -257,7 +257,8 @@ static int ce_match_stat_basic(struct cache_entry *ce, struct stat *st)
static int is_racy_timestamp(const struct index_state *istate, struct cache_entry *ce)
{
- return (istate->timestamp &&
+ return (!S_ISGITLINK(ce->ce_mode) &&
+ istate->timestamp &&
((unsigned int)istate->timestamp) <= ce->ce_mtime);
}