diff options
Diffstat (limited to 'read-cache.c')
-rw-r--r-- | read-cache.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/read-cache.c b/read-cache.c index 967f483f78..525d138e90 100644 --- a/read-cache.c +++ b/read-cache.c @@ -1239,6 +1239,11 @@ unmap: die("index file corrupt"); } +int is_index_unborn(struct index_state *istate) +{ + return (!istate->cache_nr && !istate->alloc && !istate->timestamp); +} + int discard_index(struct index_state *istate) { istate->cache_nr = 0; |