diff options
author | Patrick Steinhardt <ps@pks.im> | 2024-09-05 12:09:31 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2024-09-05 17:49:12 +0200 |
commit | ee087c29c89ad54980f2521641f5f182f6adbc79 (patch) | |
tree | a9a1e82fc009128bc50c0c279f4ce5c22484367f /t/t6132-pathspec-exclude.sh | |
parent | builtin/pack-objects: plug leaking list of keep-packs (diff) | |
download | git-ee087c29c89ad54980f2521641f5f182f6adbc79.tar.xz git-ee087c29c89ad54980f2521641f5f182f6adbc79.zip |
builtin/grep: fix leaking object context
Even when `get_oid_with_context()` fails it may have allocated some data
in the object context. But we do not release it in git-grep(1) when the
call fails, leading to a memory leak. Plug it.
Signed-off-by: Patrick Steinhardt <ps@pks.im>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t6132-pathspec-exclude.sh')
-rwxr-xr-x | t/t6132-pathspec-exclude.sh | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/t/t6132-pathspec-exclude.sh b/t/t6132-pathspec-exclude.sh index 9fdafeb1e9..f31c09c056 100755 --- a/t/t6132-pathspec-exclude.sh +++ b/t/t6132-pathspec-exclude.sh @@ -2,6 +2,7 @@ test_description='test case exclude pathspec' +TEST_PASSES_SANITIZE_LEAK=true . ./test-lib.sh test_expect_success 'setup' ' |