bpf: fix segfault in test_verifier selftest
Subsystems (5)
Daniel Borkmann
maintainerPATCH 1/1 bpf: fix segfault in test_verifier selftest
Minor fallout from merge resolution, test_verifier was segfaulting because the REJECT result was correct, but errstr was NULL. Properly fix it as in 339bbff2d6e0.
Fixes 339bbff2d6e0 ("Merge git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next")
Signed-off-by Daniel Borkmann <[email protected]>
---
[ Hi David, would be great if you could take it directly, thanks! ]
tools/testing/selftests/bpf/test_verifier.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
tools/testing/selftests/bpf/test_verifier.c +2 -1
@@ -14194,7 +14194,8 @@ static struct bpf_test tests[] = { }, .prog_type = BPF_PROG_TYPE_SOCKET_FILTER, .errstr_unpriv = "function calls to other bpf functions are allowed for root only", - .result = REJECT, + .errstr = "!read_ok", + .result = REJECT, }, { "jset: functional",
Signature · 1 line
2.17.1
From: Daniel Borkmann <[email protected]>
Date: Fri, 21 Dec 2018 14:04:46 +0100
Quoted 8 lines
Minor fallout from merge resolution,
test_verifierwas segfaulting because the REJECT result was correct, but errstr was NULL. Properly fix it as in339bbff2d6e0.Fixes 339bbff2d6e0 ("Merge git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next")Signed-off-by Daniel Borkmann <[email protected]>---
[ Hi David, would be great if you could take it directly, thanks! ]
I'll learn how to resolve conflicts properly some day :-)
Applied, thanks Daniel.