]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
selftests/bpf: Add negative test cases for snprintf
authorPaul Chaignon <paul.chaignon@gmail.com>
Tue, 1 Jul 2025 19:48:03 +0000 (21:48 +0200)
committerAlexei Starovoitov <ast@kernel.org>
Tue, 1 Jul 2025 22:22:46 +0000 (15:22 -0700)
commitbf4807c89d8f92c47404b1e4eeeefb42259d1b50
tree05420dd3623b9445124ae1fabf8446c47c35b9ca
parentf8242745871f81a3ac37f9f51853d12854fd0b58
selftests/bpf: Add negative test cases for snprintf

This patch adds a couple negative test cases with a trailing % at the
end of the format string. The %p% case was fixed by the previous commit,
whereas the %s% case was already successfully rejected before.

Acked-by: Yonghong Song <yonghong.song@linux.dev>
Signed-off-by: Paul Chaignon <paul.chaignon@gmail.com>
Link: https://lore.kernel.org/r/0669bf6eb4f9e5bb10e949d60311c06e2d942447.1751395489.git.paul.chaignon@gmail.com
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
tools/testing/selftests/bpf/prog_tests/snprintf.c