summaryrefslogtreecommitdiff
path: root/builtin/commit.c
diff options
context:
space:
mode:
authorPatrick Steinhardt <ps@pks.im>2024-08-14 08:52:12 +0200
committerJunio C Hamano <gitster@pobox.com>2024-08-14 10:07:58 -0700
commit5f6519b62c636edfff4e1ffd6591917a53616b42 (patch)
tree1eac93674c6c7e749d32ca5d14d3a284e1072979 /builtin/commit.c
parentd1c53f6703f34eeb3442070016db6e4d1f5676d2 (diff)
submodule-config: fix leaking name entry when traversing submodules
We traverse through submodules in the tree via `tree_entry()`, passing to it a `struct name_entry` that it is supposed to populate with the tree entry's contents. We unnecessarily allocate this variable instead of passing a variable that is allocated on the stack, and the ultimately don't even free that variable. This is unnecessary and leaks memory. Convert the variable to instead be allocated on the stack to plug the memory leak. Signed-off-by: Patrick Steinhardt <ps@pks.im> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/commit.c')
0 files changed, 0 insertions, 0 deletions