split-index: do not invalidate cache-tree at read time

We are sure that after merge_base_index() is done. cache-tree can
still be used with the final index. So don't destroy cache tree.

Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Nguyễn Thái Ngọc Duy
2014-06-13 19:19:42 +07:00
committed by Junio C Hamano
parent 76b07b37a3
commit ce7c614bce
3 changed files with 4 additions and 1 deletions

View File

@ -133,6 +133,7 @@ void merge_base_index(struct index_state *istate)
for (i = si->nr_replacements; i < si->saved_cache_nr; i++) {
add_index_entry(istate, si->saved_cache[i],
ADD_CACHE_OK_TO_ADD |
ADD_CACHE_KEEP_CACHE_TREE |
/*
* we may have to replay what
* merge-recursive.c:update_stages()