]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commit
selftests/bpf/test_progs: do not check errno == 0
authorMauricio Vasquez B <mauricio.vasquez@polito.it>
Mon, 3 Sep 2018 17:01:59 +0000 (19:01 +0200)
committerAlexei Starovoitov <ast@kernel.org>
Fri, 7 Sep 2018 05:34:08 +0000 (22:34 -0700)
commitf5bd3948eb07e76fcd73d0b8ab7b3265be226038
tree9ad9a009961dc85c1ac826f34f04b3a729dd2d1e
parentad1242d8a063ceb8c6e1b9c1a63b73ec94fa0295
selftests/bpf/test_progs: do not check errno == 0

The errno man page states: "The value in errno is significant only when
the return value of the call indicated an error..." then it is not correct
to check it, it could be different than zero even if the function
succeeded.

It causes some false positives if errno is set by a previous function.

Signed-off-by: Mauricio Vasquez B <mauricio.vasquez@polito.it>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
tools/testing/selftests/bpf/test_progs.c