Skip to content

Commit 8692755

Browse files
committed
Merge pull request #1827 from benpeart/fscache_refresh_index
Enable the filesystem cache (fscache) in refresh_index().
2 parents 7b24234 + 4dd09d1 commit 8692755

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

read-cache.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1526,6 +1526,7 @@ int refresh_index(struct index_state *istate, unsigned int flags,
15261526
typechange_fmt = in_porcelain ? "T\t%s\n" : "%s: needs update\n";
15271527
added_fmt = in_porcelain ? "A\t%s\n" : "%s: needs update\n";
15281528
unmerged_fmt = in_porcelain ? "U\t%s\n" : "%s: needs merge\n";
1529+
enable_fscache(1);
15291530
/*
15301531
* Use the multi-threaded preload_index() to refresh most of the
15311532
* cache entries quickly then in the single threaded loop below,
@@ -1620,6 +1621,7 @@ int refresh_index(struct index_state *istate, unsigned int flags,
16201621
display_progress(progress, istate->cache_nr);
16211622
stop_progress(&progress);
16221623
trace_performance_leave("refresh index");
1624+
enable_fscache(0);
16231625
return has_errors;
16241626
}
16251627

0 commit comments

Comments
 (0)