]> git.ipfire.org Git - thirdparty/git.git/commit
config: plug various memory leaks
authorPatrick Steinhardt <ps@pks.im>
Mon, 27 May 2024 11:46:44 +0000 (13:46 +0200)
committerJunio C Hamano <gitster@pobox.com>
Mon, 27 May 2024 18:20:00 +0000 (11:20 -0700)
commit49eb597ce08de7fc4837155fa7910dace92b9ae6
tree1f425f0483e0c7355ae17bd34c5fbb334b08dabc
parent1b261c20ed28ad26ddbcd3dff94a248ac6866ac8
config: plug various memory leaks

Now that memory ownership rules around `git_config_string()` and
`git_config_pathname()` are clearer, it also got easier to spot that
the returned memory needs to be free'd. Plug a subset of those cases and
mark now-passing tests as leak free.

Signed-off-by: Patrick Steinhardt <ps@pks.im>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
13 files changed:
alias.c
config.c
t/t1306-xdg-files.sh
t/t1350-config-hooks-path.sh
t/t3415-rebase-autosquash.sh
t/t4041-diff-submodule-option.sh
t/t4060-diff-submodule-option-diff-format.sh
t/t4210-log-i18n.sh
t/t6006-rev-list-format.sh
t/t7005-editor.sh
t/t7102-reset.sh
t/t9129-git-svn-i18n-commitencoding.sh
t/t9139-git-svn-non-utf8-commitencoding.sh