Lines Matching refs:server_fd
154 static int run_test(int cgroup_fd, int server_fd, bool is_mptcp)
173 client_fd = connect_to_fd(server_fd, 0);
192 int server_fd, cgroup_fd;
203 server_fd = start_server(AF_INET, SOCK_STREAM, NULL, 0, 0);
204 if (!ASSERT_GE(server_fd, 0, "start_server"))
207 ASSERT_OK(run_test(cgroup_fd, server_fd, false), "run_test tcp");
209 close(server_fd);
213 server_fd = start_mptcp_server(AF_INET, NULL, 0, 0);
214 if (!ASSERT_GE(server_fd, 0, "start_mptcp_server"))
217 ASSERT_OK(run_test(cgroup_fd, server_fd, true), "run_test mptcp");
219 close(server_fd);
233 static int verify_mptcpify(int server_fd, int client_fd)
241 if (!ASSERT_OK(getsockopt(server_fd, SOL_SOCKET, SO_PROTOCOL, &protocol, &optlen),
267 int server_fd, client_fd, err = 0;
281 server_fd = start_server(AF_INET, SOCK_STREAM, NULL, 0, 0);
282 if (!ASSERT_GE(server_fd, 0, "start_server")) {
287 client_fd = connect_to_fd(server_fd, 0);
295 err = verify_mptcpify(server_fd, client_fd);
299 close(server_fd);
362 int server_fd, client_fd, err;
368 server_fd = start_mptcp_server(AF_INET, ADDR_1, PORT_1, 0);
369 if (!ASSERT_OK_FD(server_fd, "start_mptcp_server"))
372 client_fd = connect_to_fd(server_fd, 0);
393 close(server_fd);