]> git.ipfire.org Git - thirdparty/git.git/commit
builtin/commit: fix leaking cleanup config
authorPatrick Steinhardt <ps@pks.im>
Tue, 5 Nov 2024 06:17:20 +0000 (07:17 +0100)
committerJunio C Hamano <gitster@pobox.com>
Tue, 5 Nov 2024 06:37:54 +0000 (22:37 -0800)
commit6ef9f77a15fcb198b59840a9ed3a8f88da5ad53d
tree2a19d80ba9b18b7175304bc32d2a62e677743627
parentff31b7b941286d91d03ddf4faac22b99149ea4b1
builtin/commit: fix leaking cleanup config

The cleanup string set by the config is leaking when it is being
overridden by an option. Fix this by tracking these via two separate
variables such that we can free the old value.

Signed-off-by: Patrick Steinhardt <ps@pks.im>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/commit.c
t/t7502-commit-porcelain.sh