summaryrefslogtreecommitdiff
path: root/tools/testing
diff options
context:
space:
mode:
authorMykyta Yatsenko <yatsenko@meta.com>2025-06-17 13:15:36 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2025-08-15 16:38:38 +0200
commitf02cb9461f731b29b3fd3bef05570573c6666689 (patch)
tree37e754a1543c2ba15121ccddcfc40e711a39d4aa /tools/testing
parent261b30ad1516f4b9edd500aa6e8d6315c8fc109a (diff)
downloadlinux-f02cb9461f731b29b3fd3bef05570573c6666689.tar.gz
linux-f02cb9461f731b29b3fd3bef05570573c6666689.tar.bz2
linux-f02cb9461f731b29b3fd3bef05570573c6666689.zip
selftests/bpf: Fix unintentional switch case fall through
[ Upstream commit 66ab68c9de89672366fdc474f4f185bb58cecf2d ] Break from switch expression after parsing -n CLI argument in veristat, instead of falling through and enabling comparison mode. Fixes: a5c57f81eb2b ("veristat: add ability to set BPF_F_TEST_SANITY_STRICT flag with -r flag") Signed-off-by: Mykyta Yatsenko <yatsenko@meta.com> Signed-off-by: Andrii Nakryiko <andrii@kernel.org> Acked-by: Yonghong Song <yonghong.song@linux.dev> Link: https://lore.kernel.org/bpf/20250617121536.1320074-1-mykyta.yatsenko5@gmail.com Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'tools/testing')
-rw-r--r--tools/testing/selftests/bpf/veristat.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/testing/selftests/bpf/veristat.c b/tools/testing/selftests/bpf/veristat.c
index b2bb20b00952..adf948fff211 100644
--- a/tools/testing/selftests/bpf/veristat.c
+++ b/tools/testing/selftests/bpf/veristat.c
@@ -344,6 +344,7 @@ static error_t parse_arg(int key, char *arg, struct argp_state *state)
fprintf(stderr, "invalid top N specifier: %s\n", arg);
argp_usage(state);
}
+ break;
case 'C':
env.comparison_mode = true;
break;