Skip to content

Commit 81c9259

Browse files
committed
Merge pull request git-for-windows#1827 from benpeart/fscache_refresh_index
Enable the filesystem cache (fscache) in refresh_index().
2 parents 8021a2f + 39f1de3 commit 81c9259

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

read-cache.c

+2
Original file line numberDiff line numberDiff line change
@@ -1532,6 +1532,7 @@ int refresh_index(struct index_state *istate, unsigned int flags,
15321532
typechange_fmt = in_porcelain ? "T\t%s\n" : "%s: needs update\n";
15331533
added_fmt = in_porcelain ? "A\t%s\n" : "%s: needs update\n";
15341534
unmerged_fmt = in_porcelain ? "U\t%s\n" : "%s: needs merge\n";
1535+
enable_fscache(1);
15351536
/*
15361537
* Use the multi-threaded preload_index() to refresh most of the
15371538
* cache entries quickly then in the single threaded loop below,
@@ -1626,6 +1627,7 @@ int refresh_index(struct index_state *istate, unsigned int flags,
16261627
display_progress(progress, istate->cache_nr);
16271628
stop_progress(&progress);
16281629
trace_performance_leave("refresh index");
1630+
enable_fscache(0);
16291631
return has_errors;
16301632
}
16311633

0 commit comments

Comments
 (0)