diff options
author | Ævar Arnfjörð Bjarmason <avarab@gmail.com> | 2021-12-22 05:06:42 +0100 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2021-12-22 16:24:13 -0800 |
commit | f2919bae9836d552a399b67f4f7d26d30128b6d5 (patch) | |
tree | b8963d510b6c82c326257894075fa93e813bb0c4 /t/t4013/diff.diff_--dirstat_--cc_master~1_master | |
parent | reflog expire: narrow scope of "cb" in cmd_reflog_expire() (diff) | |
download | tgif-f2919bae9836d552a399b67f4f7d26d30128b6d5.tar.xz |
reflog: change one->many worktree->refnames to use a string_list
Change the FLEX_ARRAY pattern added in bda3a31cc79 (reflog-expire:
Avoid creating new files in a directory inside readdir(3) loop,
2008-01-25) the string-list API instead.
This does not change any behavior, allows us to delete much of this
code as it's replaced by things we get from the string-list API for
free, as a result we need just one struct to keep track of this data,
instead of two.
The "DUP" -> "string_list_append_nodup(..., strbuf_detach(...))"
pattern here is the same as that used in a recent memory leak fix in
b202e51b154 (grep: fix a "path_list" memory leak, 2021-10-22).
Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t4013/diff.diff_--dirstat_--cc_master~1_master')
0 files changed, 0 insertions, 0 deletions