Skip to content

Commit 3fbf377

Browse files
committed
Merge pull request #1827 from benpeart/fscache_refresh_index
Enable the filesystem cache (fscache) in refresh_index().
2 parents 60dd0dd + 6b86786 commit 3fbf377

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
@@ -1631,6 +1631,7 @@ int refresh_index(struct index_state *istate, unsigned int flags,
16311631
typechange_fmt = in_porcelain ? "T\t%s\n" : "%s: needs update\n";
16321632
added_fmt = in_porcelain ? "A\t%s\n" : "%s: needs update\n";
16331633
unmerged_fmt = in_porcelain ? "U\t%s\n" : "%s: needs merge\n";
1634+
enable_fscache(1);
16341635
/*
16351636
* Use the multi-threaded preload_index() to refresh most of the
16361637
* cache entries quickly then in the single threaded loop below,
@@ -1725,6 +1726,7 @@ int refresh_index(struct index_state *istate, unsigned int flags,
17251726
display_progress(progress, istate->cache_nr);
17261727
stop_progress(&progress);
17271728
trace_performance_leave("refresh index");
1729+
enable_fscache(0);
17281730
return has_errors;
17291731
}
17301732

0 commit comments

Comments
 (0)