/freebsd-10.0-release/lib/libstand/ |
H A D | bootparam.h | 3 int bp_whoami(int sock); 4 int bp_getfile(int sock, char *key, struct in_addr *addrp, char *path);
|
/freebsd-10.0-release/tools/regression/sockets/listen_backlog/ |
H A D | listen_backlog.c | 69 socket_get_backlog(int sock, int *backlogp, const char *testclass, argument 76 if (getsockopt(sock, SOL_SOCKET, SO_LISTENQLIMIT, &i, &len) < 0) { 105 int backlog_retrieved, sock; local 107 sock = socket(domain, type, protocol); 108 if (sock < 0) { 111 close(sock); 115 if (socket_get_backlog(sock, &backlog_retrieved, testclass, test, 117 close(sock); 125 close(sock); 129 if (listen(sock, backlo 164 int sock; local 226 int backlog_retrieved, sock; local 289 int sock; local 344 int i, ret, sock; local [all...] |
/freebsd-10.0-release/contrib/sendmail/contrib/ |
H A D | socketmapClient.pl | 14 my $sock; 17 $sock = new IO::Socket::INET ( 23 $sock = new IO::Socket::UNIX ( 31 die "Could not create socket: $!\n" unless $sock; 35 netstringWrite($sock, $request); 36 $sock->flush(); 37 my $response = netstringRead($sock); 42 $sock->close(); 45 my $sock = shift; 48 print $sock lengt [all...] |
H A D | socketmapServer.pl | 11 my $sock; 14 $sock = new IO::Socket::INET ( 23 $sock = new IO::Socket::UNIX ( 32 while(my $client = $sock->accept()) { 38 $sock->close(); 45 $sock->close(); 76 my $sock = shift; 79 print $sock length($data).':'.$data.','; 83 my $sock = shift; 86 my $dataLength = <$sock>; [all...] |
/freebsd-10.0-release/tools/regression/sockets/shutdown/ |
H A D | shutdown.c | 43 struct sockaddr_in sock; local 59 bzero(&sock, sizeof(sock)); 60 sock.sin_len = sizeof(sock); 61 sock.sin_family = AF_INET; 62 sock.sin_addr.s_addr = htonl(INADDR_LOOPBACK); 63 sock.sin_port = 0; 65 if (bind(listen_sock, (struct sockaddr *)&sock, sizeof(sock)) < [all...] |
/freebsd-10.0-release/tools/regression/sockets/unix_socket/ |
H A D | unix_socket.c | 45 int sock, socks[2]; local 47 sock = socket(PF_LOCAL, SOCK_STREAM, 0); 48 if (sock < 0) 50 close(sock); 52 sock = socket(PF_LOCAL, SOCK_DGRAM, 0); 53 if (sock < 0) 55 close(sock); 57 sock = socket(PF_LOCAL, SOCK_RAW, 0); 58 if (sock >= 0) { 59 close(sock); [all...] |
/freebsd-10.0-release/contrib/ntp/libntp/ |
H A D | socktohost.c | 20 struct sockaddr_storage* sock 26 if (getnameinfo((struct sockaddr *)sock, SOCKLEN(sock), buffer, 28 return stoa(sock);
|
H A D | socktoa.c | 26 struct sockaddr_storage* sock 33 if (sock == NULL) 38 switch(sock->ss_family) { 42 inet_ntop(AF_INET, &GET_INADDR(*sock), buffer, 47 inet_ntop(AF_INET6, &GET_INADDR6(*sock), buffer,
|
/freebsd-10.0-release/crypto/heimdal/lib/kadm5/ |
H A D | send_recv.c | 44 krb5_storage *sock; local 46 assert(context->sock != -1); 62 sock = krb5_storage_from_fd(context->sock); 63 if(sock == NULL) { 69 ret = krb5_store_data(sock, out); 72 krb5_storage_free(sock); 82 krb5_storage *sock; local 84 sock = krb5_storage_from_fd(context->sock); [all...] |
/freebsd-10.0-release/tools/regression/sockets/rtsocket/ |
H A D | rtsocket.c | 46 int sock, socks[2]; local 48 sock = socket(PF_ROUTE, SOCK_STREAM, 0); 49 if (sock >= 0) { 50 close(sock); 52 sock); 58 sock = socket(PF_ROUTE, SOCK_DGRAM, 0); 59 if (sock >= 0) { 60 close(sock); 62 sock); 68 sock [all...] |
/freebsd-10.0-release/contrib/apr/network_io/unix/ |
H A D | sockopt.c | 75 apr_status_t apr_socket_timeout_set(apr_socket_t *sock, apr_interval_time_t t) argument 86 if (t >= 0 && sock->timeout < 0) { 87 if (apr_is_option_set(sock, APR_SO_NONBLOCK) != 1) { 88 if ((stat = sononblock(sock->socketdes)) != APR_SUCCESS) { 91 apr_set_option(sock, APR_SO_NONBLOCK, 1); 94 else if (t < 0 && sock->timeout >= 0) { 95 if (apr_is_option_set(sock, APR_SO_NONBLOCK) != 0) { 96 if ((stat = soblock(sock->socketdes)) != APR_SUCCESS) { 99 apr_set_option(sock, APR_SO_NONBLOCK, 0); 106 sock 113 apr_socket_opt_set(apr_socket_t *sock, apr_int32_t opt, apr_int32_t on) argument 329 apr_socket_timeout_get(apr_socket_t *sock, apr_interval_time_t *t) argument 336 apr_socket_opt_get(apr_socket_t *sock, apr_int32_t opt, apr_int32_t *on) argument 347 apr_socket_atmark(apr_socket_t *sock, int *atmark) argument 384 apr_socket_accept_filter(apr_socket_t *sock, char *nonconst_name, char *nonconst_args) argument [all...] |
H A D | sockets.c | 31 static apr_status_t socket_cleanup(void *sock) argument 33 apr_socket_t *thesocket = sock; 52 static void set_socket_vars(apr_socket_t *sock, int family, int type, int protocol) argument 54 sock->type = type; 55 sock->protocol = protocol; 56 apr_sockaddr_vars_set(sock->local_addr, family, 0); 57 apr_sockaddr_vars_set(sock->remote_addr, family, 0); 58 sock->options = 0; 63 sock->options |= APR_TCP_NODELAY; 85 apr_status_t apr_socket_protocol_get(apr_socket_t *sock, in argument 177 apr_socket_bind(apr_socket_t *sock, apr_sockaddr_t *sa) argument 193 apr_socket_listen(apr_socket_t *sock, apr_int32_t backlog) argument 201 apr_socket_accept(apr_socket_t **new, apr_socket_t *sock, apr_pool_t *connection_context) argument 312 apr_socket_connect(apr_socket_t *sock, apr_sockaddr_t *sa) argument 384 apr_socket_type_get(apr_socket_t *sock, int *type) argument 390 apr_socket_data_get(void **data, const char *key, apr_socket_t *sock) argument 407 apr_socket_data_set(apr_socket_t *sock, void *data, const char *key, apr_status_t (*cleanup) (void *)) argument 424 apr_os_sock_get(apr_os_sock_t *thesock, apr_socket_t *sock) argument 468 apr_os_sock_put(apr_socket_t **sock, apr_os_sock_t *thesock, apr_pool_t *cont) argument [all...] |
H A D | multicast.c | 95 static int sock_is_ipv4(apr_socket_t *sock) argument 97 if (sock->local_addr->family == APR_INET) 103 static int sock_is_ipv6(apr_socket_t *sock) argument 105 if (sock->local_addr->family == APR_INET6) 111 static apr_status_t do_mcast(int type, apr_socket_t *sock, argument 127 if (sock_is_ipv4(sock)) { 131 else if (sock_is_ipv6(sock)) { 150 if (setsockopt(sock->socketdes, ip_proto, type, (const void *) &mip, 160 if (sock_is_ipv4(sock)) { 164 if (setsockopt(sock 199 do_mcast_opt(int type, apr_socket_t *sock, apr_byte_t value) argument [all...] |
H A D | sendrecv.c | 30 apr_status_t apr_socket_send(apr_socket_t *sock, const char *buf, argument 35 if (sock->options & APR_INCOMPLETE_WRITE) { 36 sock->options &= ~APR_INCOMPLETE_WRITE; 41 rv = write(sock->socketdes, buf, (*len)); 45 && (sock->timeout > 0)) { 48 arv = apr_wait_for_io_or_timeout(NULL, sock, 0); 55 rv = write(sock->socketdes, buf, (*len)); 63 if ((sock->timeout > 0) && (rv < *len)) { 64 sock->options |= APR_INCOMPLETE_WRITE; 70 apr_status_t apr_socket_recv(apr_socket_t *sock, cha argument 112 apr_socket_sendto(apr_socket_t *sock, apr_sockaddr_t *where, apr_int32_t flags, const char *buf, apr_size_t *len) argument 146 apr_socket_recvfrom(apr_sockaddr_t *from, apr_socket_t *sock, apr_int32_t flags, char *buf, apr_size_t *len) argument 194 apr_socket_sendv(apr_socket_t * sock, const struct iovec *vec, apr_int32_t nvec, apr_size_t *len) argument 257 apr_socket_sendfile(apr_socket_t *sock, apr_file_t *file, apr_hdtr_t *hdtr, apr_off_t *offset, apr_size_t *len, apr_int32_t flags) argument 413 apr_socket_sendfile(apr_socket_t *sock, apr_file_t *file, apr_hdtr_t *hdtr, apr_off_t *offset, apr_size_t *len, apr_int32_t flags) argument 531 apr_socket_sendfile(apr_socket_t * sock, apr_file_t * file, apr_hdtr_t * hdtr, apr_off_t * offset, apr_size_t * len, apr_int32_t flags) argument 667 apr_socket_sendfile(apr_socket_t *sock, apr_file_t *file, apr_hdtr_t *hdtr, apr_off_t *offset, apr_size_t *len, apr_int32_t flags) argument 815 apr_socket_sendfile(apr_socket_t * sock, apr_file_t * file, apr_hdtr_t * hdtr, apr_off_t * offset, apr_size_t * len, apr_int32_t flags) argument 977 apr_socket_sendfile(apr_socket_t *sock, apr_file_t *file, apr_hdtr_t *hdtr, apr_off_t *offset, apr_size_t *len, apr_int32_t flags) argument [all...] |
/freebsd-10.0-release/tools/regression/netinet/ipsockopt/ |
H A D | ipsockopt.c | 77 int sock; local 86 sock = socket(PF_INET, type, 0); 91 return (sock); 114 test_ip_options(int sock, const char *socktypename) argument 124 if (getsockopt(sock, IPPROTO_IP, IP_OPTIONS, test_options, &len) < 0) 140 if (setsockopt(sock, IPPROTO_IP, IP_OPTIONS, &new_options, 154 if (getsockopt(sock, IPPROTO_IP, IP_OPTIONS, test_options, &len) < 0) 184 if (setsockopt(sock, IPPROTO_IP, IP_OPTIONS, NULL, 0) < 0) 194 if (getsockopt(sock, IPPROTO_IP, IP_OPTIONS, test_options, &len) < 0) 217 int flag[2], sock; local 391 test_ip_uchar(int sock, const char *socktypename, int option, const char *optionname, int initial) argument 531 test_ip_boolean(int sock, const char *socktypename, int option, char *optionname, int initial, int rootonly) argument 641 test_ip_multicast_membership(int sock, const char *socktypename) argument 714 test_ip_multicast_if(int sock, const char *socktypename) argument 727 test_ip_multicast_vif(int sock, const char *socktypename) argument 743 int i, sock, socktype; local [all...] |
/freebsd-10.0-release/crypto/heimdal/appl/test/ |
H A D | nt_gss_common.h | 36 void nt_write_token (int sock, gss_buffer_t buf); 37 void nt_read_token (int sock, gss_buffer_t buf);
|
H A D | gss_common.h | 36 void write_token (int sock, gss_buffer_t buf); 37 void read_token (int sock, gss_buffer_t buf);
|
/freebsd-10.0-release/tools/regression/sockets/sigpipe/ |
H A D | sigpipe.c | 88 test_send(const char *testname, int sock) argument 94 len = send(sock, &ch, sizeof(ch), 0); 104 test_write(const char *testname, int sock) argument 110 len = write(sock, &ch, sizeof(ch)); 218 tcp_pair(u_short port, int sock[2]) argument 246 sock[0] = accept_sock; 247 sock[1] = connect_sock; 254 int sock[2]; local 271 if (socketpair(PF_LOCAL, SOCK_STREAM, 0, sock) < 0) 273 test_send_wantsignal("test_send_wantsignal(PF_LOCAL)", sock[ [all...] |
/freebsd-10.0-release/contrib/openbsm/bin/auditdistd/ |
H A D | proto_common.c | 54 blocking_socket(int sock) argument 58 flags = fcntl(sock, F_GETFL); 64 proto_descriptor_send(int sock, int fd) argument 70 PJDLOG_ASSERT(sock >= 0); 87 if (sendmsg(sock, &msg, 0) == -1) 94 proto_common_send(int sock, const unsigned char *data, size_t size, int fd) argument 100 PJDLOG_ASSERT(sock >= 0); 107 if (shutdown(sock, SHUT_RD) == -1) 117 done = send(sock, data, sendsize, MSG_NOSIGNAL); 146 if (errno == EAGAIN && blocking_socket(sock)) 164 proto_descriptor_recv(int sock, int *fdp) argument 195 proto_common_recv(int sock, unsigned char *data, size_t size, int *fdp) argument [all...] |
/freebsd-10.0-release/sbin/hastd/ |
H A D | proto_common.c | 53 blocking_socket(int sock) argument 57 flags = fcntl(sock, F_GETFL); 63 proto_descriptor_send(int sock, int fd) argument 69 PJDLOG_ASSERT(sock >= 0); 86 if (sendmsg(sock, &msg, 0) == -1) 93 proto_common_send(int sock, const unsigned char *data, size_t size, int fd) argument 99 PJDLOG_ASSERT(sock >= 0); 106 if (shutdown(sock, SHUT_RD) == -1) 116 done = send(sock, data, sendsize, MSG_NOSIGNAL); 145 if (errno == EAGAIN && blocking_socket(sock)) 163 proto_descriptor_recv(int sock, int *fdp) argument 194 proto_common_recv(int sock, unsigned char *data, size_t size, int *fdp) argument [all...] |
/freebsd-10.0-release/tools/regression/netinet/rawconnect/ |
H A D | rawconnect.c | 56 int sock; local 67 sock = socket(PF_INET, SOCK_RAW, IPPROTO_IP); 68 if (sock == -1) 71 if (connect(sock, (struct sockaddr *)&sin, sizeof(sin)) == -1) 74 close(sock);
|
/freebsd-10.0-release/tools/regression/sockets/fstat/ |
H A D | fstat.c | 46 int sock; local 48 sock = socket(domain, type, protocol); 49 if (sock < 0) 52 if (fstat(sock, &sb) < 0) 56 close(sock);
|
/freebsd-10.0-release/tools/regression/sockets/reconnect/ |
H A D | reconnect.c | 69 int sock; local 75 sock = socket(PF_LOCAL, SOCK_DGRAM, 0); 76 if (sock == -1) 78 setsockopt(sock, SOL_SOCKET, SO_REUSEADDR, &sock, sizeof(sock)); 79 if (bind(sock, sstosa(&ifsun), sizeof(ifsun)) < 0) 82 return sock; 86 connect_uds_server(int sock, const char *path) argument 93 e = connect(sock, sstos [all...] |
/freebsd-10.0-release/crypto/heimdal/appl/gssmask/ |
H A D | common.h | 73 if (krb5_ret_int16((_client)->sock, &(num)) != 0) \ 79 if (krb5_ret_int32((_client)->sock, &(num)) != 0) \ 85 if (krb5_ret_data((_client)->sock, &(data)) != 0) \ 91 if (krb5_ret_string((_client)->sock, &(data)) != 0) \ 98 if (krb5_store_int32((_client)->sock, num) != 0) \ 104 if (krb5_store_data((_client)->sock, data) != 0) \ 110 if (store_string((_client)->sock, str) != 0) \
|
/freebsd-10.0-release/contrib/apr/include/ |
H A D | apr_network_io.h | 311 * @param sock The socket to bind 316 APR_DECLARE(apr_status_t) apr_socket_bind(apr_socket_t *sock, 321 * @param sock The socket to listen on 326 APR_DECLARE(apr_status_t) apr_socket_listen(apr_socket_t *sock, 334 * @param sock The socket we are listening on. 338 apr_socket_t *sock, 344 * @param sock The socket we wish to use for our side of the connection 347 APR_DECLARE(apr_status_t) apr_socket_connect(apr_socket_t *sock, 356 * @param sock The socket to check 362 APR_DECLARE(apr_status_t) apr_socket_atreadeof(apr_socket_t *sock, [all...] |