diff options
author | Ævar Arnfjörð Bjarmason <avarab@gmail.com> | 2021-10-21 22:54:14 +0300 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2021-10-22 02:26:45 +0300 |
commit | 25ad722126c77a546ab1ac7111f090bd8d0e3c13 (patch) | |
tree | 38b7c848341c7e6ecbe2891836fce0282bd5afc3 /t/t1305-config-include.sh | |
parent | 9d530dc0024503ab4218fe6c4395b8a0aa245478 (diff) |
config.c: don't leak memory in handle_path_include()
Fix a memory leak in the error() path in handle_path_include(), this
allows us to run t1305-config-include.sh under SANITIZE=leak,
previously 4 tests there would fail. This fixes up a leak in
9b25a0b52e0 (config: add include directive, 2012-02-06).
Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t1305-config-include.sh')
-rwxr-xr-x | t/t1305-config-include.sh | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/t/t1305-config-include.sh b/t/t1305-config-include.sh index ccbb116c01..5cde79ef8c 100755 --- a/t/t1305-config-include.sh +++ b/t/t1305-config-include.sh @@ -1,6 +1,7 @@ #!/bin/sh test_description='test config file include directives' +TEST_PASSES_SANITIZE_LEAK=true . ./test-lib.sh # Force setup_explicit_git_dir() to run until the end. This is needed |