diff options
author | Lorenz Bauer <lmb@isovalent.com> | 2023-04-13 10:47:40 +0100 |
---|---|---|
committer | Daniel Borkmann <daniel@iogearbox.net> | 2023-04-13 14:17:02 +0200 |
commit | 5a674611d116a5fc28c5429beea2b78c6e2933ef (patch) | |
tree | aac535ef15c7a1fbfb8258a9df7f32f7b35d3177 /tools | |
parent | d319f344561de23e810515d109c7278919bff7b0 (diff) |
selftests/bpf: Fix use of uninitialized op_name in log tests
One of the test assertions uses an uninitialized op_name, which leads
to some headscratching if it fails. Use a string constant instead.
Fixes: b1a7a480a112 ("selftests/bpf: Add fixed vs rotating verifier log tests")
Signed-off-by: Lorenz Bauer <lmb@isovalent.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Link: https://lore.kernel.org/bpf/20230413094740.18041-1-lmb@isovalent.com
Diffstat (limited to 'tools')
-rw-r--r-- | tools/testing/selftests/bpf/prog_tests/verifier_log.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/testing/selftests/bpf/prog_tests/verifier_log.c b/tools/testing/selftests/bpf/prog_tests/verifier_log.c index 475092a78deb..8337c6bc5b95 100644 --- a/tools/testing/selftests/bpf/prog_tests/verifier_log.c +++ b/tools/testing/selftests/bpf/prog_tests/verifier_log.c @@ -110,7 +110,7 @@ static void verif_log_subtest(const char *name, bool expect_load_error, int log_ } if (!ASSERT_EQ(strlen(logs.buf), 24, "log_fixed_25")) goto cleanup; - if (!ASSERT_STRNEQ(logs.buf, logs.reference, 24, op_name)) + if (!ASSERT_STRNEQ(logs.buf, logs.reference, 24, "log_fixed_contents_25")) goto cleanup; } |