diff options
| author | Junio C Hamano <gitster@pobox.com> | 2024-08-14 14:54:47 -0700 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2024-08-14 14:54:47 -0700 |
| commit | 4385f8a52d74db55731e8bc02070151eff0fea74 (patch) | |
| tree | df2d58dab20eca6bb30e7e6ecd7c18cf571e1706 /entry.c | |
| parent | 25673b1c476756ec0587fb0596ab3c22b96dc52a (diff) | |
| parent | f30bfafcd41d0f13575361957dc361aa2be4d4c5 (diff) | |
| download | git-4385f8a52d74db55731e8bc02070151eff0fea74.tar.gz | |
Merge branch 'ps/leakfixes-part-3'
More leakfixes.
* ps/leakfixes-part-3: (24 commits)
commit-reach: fix trivial memory leak when computing reachability
convert: fix leaking config strings
entry: fix leaking pathnames during delayed checkout
object-name: fix leaking commit list items
t/test-repository: fix leaking repository
builtin/credential-cache: fix trivial leaks
builtin/worktree: fix leaking derived branch names
builtin/shortlog: fix various trivial memory leaks
builtin/rerere: fix various trivial memory leaks
builtin/credential-store: fix leaking credential
builtin/show-branch: fix several memory leaks
builtin/rev-parse: fix memory leak with `--parseopt`
builtin/stash: fix various trivial memory leaks
builtin/remote: fix various trivial memory leaks
builtin/remote: fix leaking strings in `branch_list`
builtin/ls-remote: fix leaking `pattern` strings
builtin/submodule--helper: fix leaking buffer in `is_tip_reachable`
builtin/submodule--helper: fix leaking clone depth parameter
builtin/name-rev: fix various trivial memory leaks
builtin/describe: fix trivial memory leak when describing blob
...
Diffstat (limited to 'entry.c')
| -rw-r--r-- | entry.c | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -191,7 +191,7 @@ int finish_delayed_checkout(struct checkout *state, int show_progress) progress = start_delayed_progress(_("Filtering content"), dco->paths.nr); while (dco->filters.nr > 0) { for_each_string_list_item(filter, &dco->filters) { - struct string_list available_paths = STRING_LIST_INIT_NODUP; + struct string_list available_paths = STRING_LIST_INIT_DUP; if (!async_query_available_blobs(filter->string, &available_paths)) { /* Filter reported an error */ @@ -245,6 +245,8 @@ int finish_delayed_checkout(struct checkout *state, int show_progress) } else errs = 1; } + + string_list_clear(&available_paths, 0); } filter_string_list(&dco->filters, 0, string_is_not_null, NULL); |
