Skip to content

Commit 5b50915

Browse files
committed
Merge pull request #1827 from benpeart/fscache_refresh_index
Enable the filesystem cache (fscache) in refresh_index().
2 parents ca2e5de + e1c68f7 commit 5b50915

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
@@ -1607,6 +1607,7 @@ int refresh_index(struct index_state *istate, unsigned int flags,
16071607
typechange_fmt = in_porcelain ? "T\t%s\n" : "%s: needs update\n";
16081608
added_fmt = in_porcelain ? "A\t%s\n" : "%s: needs update\n";
16091609
unmerged_fmt = in_porcelain ? "U\t%s\n" : "%s: needs merge\n";
1610+
enable_fscache(1);
16101611
/*
16111612
* Use the multi-threaded preload_index() to refresh most of the
16121613
* cache entries quickly then in the single threaded loop below,
@@ -1701,6 +1702,7 @@ int refresh_index(struct index_state *istate, unsigned int flags,
17011702
display_progress(progress, istate->cache_nr);
17021703
stop_progress(&progress);
17031704
trace_performance_leave("refresh index");
1705+
enable_fscache(0);
17041706
return has_errors;
17051707
}
17061708

0 commit comments

Comments
 (0)