Lines Matching defs:rcv_fds
29 static void build_rcv_fd(int family, int proto, int *rcv_fds, int count,
70 rcv_fds[i] = socket(family, proto, 0);
71 if (rcv_fds[i] < 0)
75 if (setsockopt(rcv_fds[i], SOL_SOCKET, SO_REUSEPORT, &opt,
79 if (bind(rcv_fds[i], addr, sz))
82 if (proto == SOCK_STREAM && listen(rcv_fds[i], 10))
175 static void test(int *rcv_fds, int count, int family, int proto, int fd)
186 ev.data.fd = rcv_fds[i];
187 if (epoll_ctl(epfd, EPOLL_CTL_ADD, rcv_fds[i], &ev))
212 int rcv_fds[10], i;
214 build_rcv_fd(AF_INET, proto, rcv_fds, 2, NULL);
215 build_rcv_fd(AF_INET6, proto, rcv_fds + 2, 2, NULL);
216 build_rcv_fd(fam_rcv, proto, rcv_fds + 4, 1, addr_str);
217 build_rcv_fd(AF_INET, proto, rcv_fds + 5, 2, NULL);
218 build_rcv_fd(AF_INET6, proto, rcv_fds + 7, 2, NULL);
219 test(rcv_fds, 9, fam_send, proto, rcv_fds[4]);
221 close(rcv_fds[i]);