[PATCH 4/4] Fix ie_match_stat for non-checked-out submodule
- From
Ping Yin <pkufranky@gmail.com>
- Date
- May 2, 2008, 13:35 UTC
- Message-ID
- <1209735336-4690-5-git-send-email-pkufranky@gmail.com>
- In-Reply-To
- <1209735336-4690-4-git-send-email-pkufranky@gmail.com>
For submodules non checked out, ie_match_stat should always return 0. So in this case avoid calling is_racy_timestamp.
Signed-off-by: Ping Yin <pkufranky@gmail.com> --- read-cache.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/read-cache.c b/read-cache.c index a92b25b..8c9c8e2 100644 --- a/read-cache.c +++ b/read-cache.c @@ -294,7 +294,7 @@ int ie_match_stat(const struct index_state *istate, * whose mtime are the same as the index file timestamp more * carefully than others. */ - if (!changed && is_racy_timestamp(istate, ce)) { + if (!changed && !S_ISGITLINK(ce->ce_mode) && is_racy_timestamp(istate, ce)) { if (assume_racy_is_modified) changed |= DATA_CHANGED; else
-- 1.5.5.1.116.ge4b9c.dirty