diff options
author | Andrii Nakryiko <andrii@kernel.org> | 2022-10-13 08:37:56 -0700 |
---|---|---|
committer | Andrii Nakryiko <andrii@kernel.org> | 2022-10-13 10:53:34 -0700 |
commit | 6e73e683b6e93f8d475ef6d6813928a860c8d124 (patch) | |
tree | 6d6022b951ecc35c07b491c489a84ac9c8a3f6a0 /tools/testing/selftests/bpf/prog_tests/tracing_struct.c | |
parent | de9c8d848d90cf2e53aced50b350827442ca5a4f (diff) | |
parent | cbc1c998da59687e8bbc4667154a72eead2daf2d (diff) |
Merge branch 'Fix bugs found by ASAN when running selftests'
Xu Kuohai says:
====================
From: Xu Kuohai <xukuohai@huawei.com>
This series fixes bugs found by ASAN when running bpf selftests on arm64.
v4:
- Address Andrii's suggestions
v3: https://lore.kernel.org/bpf/5311e154-c2d4-91a5-ccb8-f5adede579ed@huawei.com
- Fix error failure of case test_xdp_adjust_tail_grow exposed by this series
v2: https://lore.kernel.org/bpf/20221010070454.577433-1-xukuohai@huaweicloud.com
- Rebase and fix conflict
v1: https://lore.kernel.org/bpf/20221009131830.395569-1-xukuohai@huaweicloud.com
====================
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Diffstat (limited to 'tools/testing/selftests/bpf/prog_tests/tracing_struct.c')
-rw-r--r-- | tools/testing/selftests/bpf/prog_tests/tracing_struct.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/testing/selftests/bpf/prog_tests/tracing_struct.c b/tools/testing/selftests/bpf/prog_tests/tracing_struct.c index d5022b91d1e4..48dc9472e160 100644 --- a/tools/testing/selftests/bpf/prog_tests/tracing_struct.c +++ b/tools/testing/selftests/bpf/prog_tests/tracing_struct.c @@ -15,7 +15,7 @@ static void test_fentry(void) err = tracing_struct__attach(skel); if (!ASSERT_OK(err, "tracing_struct__attach")) - return; + goto destroy_skel; ASSERT_OK(trigger_module_test_read(256), "trigger_read"); @@ -54,6 +54,7 @@ static void test_fentry(void) ASSERT_EQ(skel->bss->t5_ret, 1, "t5 ret"); tracing_struct__detach(skel); +destroy_skel: tracing_struct__destroy(skel); } |