summaryrefslogtreecommitdiff
path: root/tools/testing/selftests/bpf/prog_tests/sockopt_inherit.c
AgeCommit message (Collapse)Author
2019-10-02selftests/bpf: test_progs: Don't leak server_fd in test_sockopt_inheritBrian Vazquez
server_fd needs to be closed if pthread can't be created. Fixes: e3e02e1d9c24 ("selftests/bpf: test_progs: convert test_sockopt_inherit") Signed-off-by: Brian Vazquez <brianvv@google.com> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Reviewed-by: Stanislav Fomichev <sdf@google.com> Link: https://lore.kernel.org/bpf/20191001173728.149786-3-brianvv@google.com
2019-09-06selftests/bpf: test_progs: convert test_sockopt_inheritStanislav Fomichev
Move the files, adjust includes, remove entry from Makefile & .gitignore I also added pthread_cond_wait for the server thread startup. We don't want to connect to the server that's not yet up (for some reason this existing race is now more prominent with test_progs). Signed-off-by: Stanislav Fomichev <sdf@google.com> Signed-off-by: Alexei Starovoitov <ast@kernel.org>