mirror of
https://github.com/git/git.git
synced 2026-01-12 13:53:11 +09:00
t/helper: fix leaking buffer in "dump-untracked-cache"
We never release the local `struct strbuf base` buffer, thus leaking memory. Fix this leak. This leak is exposed by t7063, but plugging it alone does not make the whole test suite pass. Signed-off-by: Patrick Steinhardt <ps@pks.im> Signed-off-by: Taylor Blau <me@ttaylorr.com>
This commit is contained in:
parent
a4a3b8c7b4
commit
44cbc97229
@ -68,5 +68,7 @@ int cmd__dump_untracked_cache(int ac UNUSED, const char **av UNUSED)
|
||||
printf("flags %08x\n", uc->dir_flags);
|
||||
if (uc->root)
|
||||
dump(uc->root, &base);
|
||||
|
||||
strbuf_release(&base);
|
||||
return 0;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user