Lines Matching defs:sock
76 int opt, status, sock, count;
111 if ((sock = socket(PF_INET6, SOCK_DGRAM, 0)) == -1) {
120 status = setpolicy(sock, policy_table, count);
124 status = setpolicy(sock, NULL, 0);
128 status = printpolicy(sock);
132 (void) close(sock);
328 * setpolicy(sock, new_policy, count)
332 * the number of entries in the table; sock should be an open INET6
336 setpolicy(int sock, ip6_asp_t *new_policy, int count)
338 if (strioctl(sock, SIOCSIP6ADDRPOLICY, new_policy,
347 * printpolicy(sock)
350 * the open socket sock, and prints the result. Returns EXIT_FAILURE
355 printpolicy(int sock)
362 if ((count = strioctl(sock, SIOCGIP6ADDRPOLICY, policy_ptr,
373 if ((count = strioctl(sock, SIOCGIP6ADDRPOLICY, policy_ptr,