leak tests: ignore some new leaks in a few tests
PATCH 1/1 leak tests: ignore some new leaks in a few tests
From: Elijah Newren <[email protected]>
These test scripts have not changed at all recently, but topics in seen have caused these to trigger the linux-leaks test. It has been reported on list, so let's fix the claim that these are leak free and when someone investigates and fixes the problem, they can turn it back on.
---
leak tests: ignore some new leaks in a few tests
linux-leaks passes when 'seen' is merged with this topic. A better fix is probably to bisect to determine which topic caused the memory leak and plug the leak in that topic (because these test scripts did not have any changes since the version when they previously passed), but a couple of quotes:
""" This is sort of water under the bridge, as the other topic is already in 'master', but come to think of it, the strategy we used with TEST_PASSES_SANITIZE_LEAK variable was misguided.
... I am tempted to drop the "TEST_PASSES" bit from this script for now, """ (from https://lore.kernel.org/git/[email protected]/)
""" But as to the "roadblock" I don't mind the TEST_PASSES_SANITIZE_LEAK=true being removed from the script at the slightest sign of trouble. Nobody should have to shift gears and chase down some memory leak... """ (from
https://lore.kernel.org/git/[email protected]/)
Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-git-1192%2Fnewren%2Fignore-leaks-v1
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-git-1192/newren/ignore-leaks-v1
Pull-Request: https://github.com/git/git/pull/1192
t/t1430-bad-ref-name.sh | 1 - t/t3211-peel-ref.sh | 1 - t/t6102-rev-list-unexpected-objects.sh | 1 - 3 files changed, 3 deletions(-)
t/t1430-bad-ref-name.sh +0 -1
@@ -4,7 +4,6 @@ test_description='Test handling of ref names that check-ref-format rejects' GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME -TEST_PASSES_SANITIZE_LEAK=true . ./test-lib.sh test_expect_success setup '
t/t3211-peel-ref.sh +0 -1
@@ -4,7 +4,6 @@ test_description='tests for the peel_ref optimization of packed-refs' GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME -TEST_PASSES_SANITIZE_LEAK=true . ./test-lib.sh test_expect_success 'create annotated tag in refs/tags' '
t/t6102-rev-list-unexpected-objects.sh +0 -1
@@ -2,7 +2,6 @@ test_description='git rev-list should handle unexpected object types' -TEST_PASSES_SANITIZE_LEAK=true . ./test-lib.sh test_expect_success 'setup well-formed objects' '
base-commit: 5ae4b10f85c8c2c00910cc805458c5c5464841e3
Signature · 1 line
gitgitgadget
Quoted 6 lines · Elijah Newren via GitGitGadget
From: Elijah Newren <[email protected]>
These test scripts have not changed at all recently, but topics in seen have caused these to trigger the linux-leaks test. It has been reported on list, so let's fix the claim that these are leak free and when someone investigates and fixes the problem, they can turn it back on.
I think this problem was likely introduced by a faulty patch in c2dbe00466 (Merge branch 'ps/avoid-unnecessary-hook-invocation-with-packed-refs' into seen, 2022-01-12), specifically 2e6b34bb1b (refs: open-code deletion of packed refs, 2022-01-07).
But the newer version 69840cc0f7 of the same patch (merged via 17d1824959) fixes the leak. As a result, all three of those once-failing tests now pass on 'seen' even when built with SANITIZE=leak.
We should be able to discard this patch as a result.
Thanks,
Taylor