summaryrefslogtreecommitdiff
path: root/read-cache.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2008-05-11 01:16:25 (GMT)
committerJunio C Hamano <gitster@pobox.com>2008-05-11 01:16:25 (GMT)
commit2855e70ad11abf7e7f30f975b063bd60d5abdf4f (patch)
tree62c02c9ba89da45a68df017332c27c281384285d /read-cache.c
parent380a7426794dcad369dd48519cd01d6e0246cde5 (diff)
parent050288d52dc5dc3f6c7716007c1069dd9f59feb7 (diff)
downloadgit-2855e70ad11abf7e7f30f975b063bd60d5abdf4f.zip
git-2855e70ad11abf7e7f30f975b063bd60d5abdf4f.tar.gz
git-2855e70ad11abf7e7f30f975b063bd60d5abdf4f.tar.bz2
Merge branch 'py/diff-submodule'
* py/diff-submodule: is_racy_timestamp(): do not check timestamp for gitlinks diff-lib.c: rename check_work_tree_entity() diff: a submodule not checked out is not modified Add t7506 to test submodule related functions for git-status t4027: test diff for submodule with empty directory
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 3b20a14..4525f8a 100644
--- a/read-cache.c
+++ b/read-cache.c
@@ -198,7 +198,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);
}