Merge branch 'ad/preload-plug-memleak' into maint
The preload-index codepath made copies of pathspec to give to multiple threads, which were left leaked. * ad/preload-plug-memleak: preload-index: fix memleak
This commit is contained in:
commit
37317ab40b
@ -151,6 +151,12 @@ void preload_index(struct index_state *index,
|
||||
}
|
||||
stop_progress(&pd.progress);
|
||||
|
||||
if (pathspec) {
|
||||
/* earlier we made deep copies for each thread to work with */
|
||||
for (i = 0; i < threads; i++)
|
||||
clear_pathspec(&data[i].pathspec);
|
||||
}
|
||||
|
||||
trace_performance_leave("preload index");
|
||||
|
||||
trace2_data_intmax("index", NULL, "preload/sum_lstat", t2_sum_lstat);
|
||||
|
Loading…
Reference in New Issue
Block a user