/freebsd-11-stable/usr.sbin/nscd/ |
H A D | singletons.h | 38 int sockfd; member in struct:runtime_env
|
H A D | nscdcli.h | 38 int sockfd; member in struct:nscd_connection_
|
H A D | nscdcli.c | 75 s_result = write(connection->sockfd, 112 s_result = read(connection->sockfd, 161 EV_SET(&eventlist, connection->sockfd, EVFILT_WRITE, EV_ADD, 167 result = (sendmsg(connection->sockfd, &cred_hdr, 0) == -1) ? -1 169 EV_SET(&eventlist, connection->sockfd, EVFILT_WRITE, EV_ADD, 211 retval->sockfd = client_socket; 216 EV_SET(&eventlist, retval->sockfd, EVFILT_WRITE, EV_ADD, 223 EV_SET(&eventlist, retval->sockfd, EVFILT_READ, EV_ADD, 238 close(connection->sockfd);
|
H A D | query.h | 79 int sockfd; /* the unix socket to read/write */ member in struct:query_state
|
H A D | nscd.c | 170 retval->sockfd = socket(PF_LOCAL, SOCK_STREAM, 0); 182 if (bind(retval->sockfd, (struct sockaddr *)&serv_addr, 184 close(retval->sockfd); 200 listen(retval->sockfd, -1); 201 fcntl(retval->sockfd, F_SETFL, O_NONBLOCK); 206 EV_SET(&eventlist, retval->sockfd, EVFILT_READ, EV_ADD | EV_ONESHOT, 221 close(env->sockfd); 503 if ((int)event_data->ident == env->sockfd) { 507 EV_SET(eventlist, s_runtime_env->sockfd,
|
/freebsd-11-stable/tests/sys/kqueue/libkqueue/ |
H A D | read.c | 21 int sockfd[2]; variable 30 if (read(sockfd[0], &buf[0], 1) < 1) 38 if (write(sockfd[1], ".", 1) < 1) 50 EV_SET(&kev, sockfd[0], EVFILT_READ, EV_ADD, 0, 0, &sockfd[0]); 65 EV_SET(&kev, sockfd[0], EVFILT_READ, EV_ADD, 0, 0, &sockfd[0]); 94 EV_SET(&kev, sockfd[0], EVFILT_READ, EV_ADD | EV_CLEAR, 0, 0, &sockfd[0]); 111 EV_SET(&kev, sockfd[ [all...] |
/freebsd-11-stable/tests/sys/audit/ |
H A D | network.c | 41 static int sockfd, sockfd2, connectfd; variable 91 ATF_REQUIRE((sockfd = socket(PF_UNIX, SOCK_STREAM, 0)) != -1); 92 /* Check the presence of sockfd in audit record */ 93 snprintf(extregex, sizeof(extregex), "socket.*ret.*success,%d", sockfd); 95 close(sockfd); 183 ATF_REQUIRE((sockfd = socket(PF_UNIX, SOCK_STREAM, 0)) != -1); 184 /* Check the presence of sockfd in audit record */ 186 "setsockopt.*0x%x.*return,success", sockfd); 189 ATF_REQUIRE_EQ(0, setsockopt(sockfd, SOL_SOCKET, 192 close(sockfd); [all...] |
/freebsd-11-stable/contrib/ldns/ |
H A D | net.c | 110 ldns_sock_nonblock(int sockfd) argument 114 if((flag = fcntl(sockfd, F_GETFL)) != -1) { 116 if(fcntl(sockfd, F_SETFL, flag) == -1) { 122 if(ioctlsocket(sockfd, FIONBIO, &on) != 0) { 130 ldns_sock_block(int sockfd) argument 134 if((flag = fcntl(sockfd, F_GETFL)) != -1) { 136 if(fcntl(sockfd, F_SETFL, flag) == -1) { 142 if(ioctlsocket(sockfd, FIONBIO, &off) != 0) { 150 ldns_sock_wait(int sockfd, struct timeval timeout, int write) argument 156 FD_SET(FD_SET_T sockfd, 177 int sockfd; local 279 int sockfd; local 317 int sockfd; local 359 int sockfd; local 377 int sockfd; local 414 int sockfd; local 648 ldns_tcp_send_query(ldns_buffer *qbin, int sockfd, const struct sockaddr_storage *to, socklen_t tolen) argument 673 ldns_udp_send_query(ldns_buffer *qbin, int sockfd, const struct sockaddr_storage *to, socklen_t tolen) argument 691 ldns_udp_read_wire(int sockfd, size_t *size, struct sockaddr_storage *from, socklen_t *fromlen) argument 721 ldns_tcp_read_wire_timeout(int sockfd, size_t *size, struct timeval timeout) argument 780 ldns_tcp_read_wire(int sockfd, size_t *size) argument [all...] |
/freebsd-11-stable/contrib/ldns/ldns/ |
H A D | net.h | 123 * \param[in] sockfd the socket to use 128 ssize_t ldns_tcp_send_query(ldns_buffer *qbin, int sockfd, const struct sockaddr_storage *to, socklen_t tolen); 134 * \param[in] sockfd the socket to use 139 ssize_t ldns_udp_send_query(ldns_buffer *qbin, int sockfd, const struct sockaddr_storage *to, socklen_t tolen); 145 * \param[in] sockfd the socket to read from 150 uint8_t *ldns_tcp_read_wire_timeout(int sockfd, size_t *size, struct timeval timeout); 157 * \param[in] sockfd the socket to read from 161 uint8_t *ldns_tcp_read_wire(int sockfd, size_t *size); 167 * \param[in] sockfd the socket to read from 173 uint8_t *ldns_udp_read_wire(int sockfd, size_ [all...] |
/freebsd-11-stable/tools/tools/nxge/ |
H A D | xge_info.c | 62 if((sockfd = socket(AF_INET, SOCK_DGRAM, 0)) < 0) { 144 if(ioctl(sockfd, SIOCGPRIVATE_0, &ifreqp) < 0) { 159 if(ioctl(sockfd, SIOCGPRIVATE_0, &ifreqp) < 0) { 202 if(ioctl(sockfd, SIOCGPRIVATE_0, &ifreqp) < 0) { 240 if(ioctl(sockfd, SIOCGPRIVATE_0, &ifreqp) < 0) { 276 if(ioctl(sockfd, SIOCGPRIVATE_0, &ifreqp) < 0) { 317 if(ioctl(sockfd, SIOCGPRIVATE_0, &ifreqp) < 0) { 363 if(ioctl(sockfd, SIOCGPRIVATE_1, &ifreqp) < 0) { 403 if(ioctl(sockfd, SIOCGPRIVATE_1, &ifreqp) < 0) { 445 if(ioctl(sockfd, SIOCGPRIVATE_ [all...] |
H A D | xge_info.h | 78 int sockfd, indexer, buffer_size = 0; variable
|
/freebsd-11-stable/contrib/ofed/libibverbs/examples/ |
H A D | xsrq_pingpong.c | 72 int sockfd; member in struct:pingpong_dest 320 int sockfd = ctx.rem_dest[index].sockfd; local 323 r = read(sockfd, msg + n, TERMINATION_MSG_SIZE - n); 345 int sockfd = ctx.rem_dest[index].sockfd; local 349 if (write(sockfd, msg, TERMINATION_MSG_SIZE) != TERMINATION_MSG_SIZE) { 384 static int send_local_dest(int sockfd, int index) argument 418 if (write(sockfd, msg, MSG_SIZE) != MSG_SIZE) { 426 static int recv_remote_dest(int sockfd, in argument 545 int sockfd = -1; local 596 int sockfd = -1, connfd; local [all...] |
H A D | ud_pingpong.c | 136 int sockfd = -1; local 152 sockfd = socket(t->ai_family, t->ai_socktype, t->ai_protocol); 153 if (sockfd >= 0) { 154 if (!connect(sockfd, t->ai_addr, t->ai_addrlen)) 156 close(sockfd); 157 sockfd = -1; 164 if (sockfd < 0) { 172 if (write(sockfd, msg, sizeof msg) != sizeof msg) { 177 if (read(sockfd, msg, sizeof msg) != sizeof msg || 178 write(sockfd, "don 211 int sockfd = -1, connfd; local [all...] |
H A D | uc_pingpong.c | 136 int sockfd = -1; local 152 sockfd = socket(t->ai_family, t->ai_socktype, t->ai_protocol); 153 if (sockfd >= 0) { 154 if (!connect(sockfd, t->ai_addr, t->ai_addrlen)) 156 close(sockfd); 157 sockfd = -1; 164 if (sockfd < 0) { 172 if (write(sockfd, msg, sizeof msg) != sizeof msg) { 177 if (read(sockfd, msg, sizeof msg) != sizeof msg || 178 write(sockfd, "don 213 int sockfd = -1, connfd; local [all...] |
H A D | srq_pingpong.c | 158 int sockfd = -1; local 174 sockfd = socket(t->ai_family, t->ai_socktype, t->ai_protocol); 175 if (sockfd >= 0) { 176 if (!connect(sockfd, t->ai_addr, t->ai_addrlen)) 178 close(sockfd); 179 sockfd = -1; 186 if (sockfd < 0) { 195 if (write(sockfd, msg, sizeof msg) != sizeof msg) { 208 r = read(sockfd, msg + n, sizeof msg - n); 223 if (write(sockfd, "don 249 int sockfd = -1, connfd; local [all...] |
H A D | rc_pingpong.c | 163 int sockfd = -1; local 179 sockfd = socket(t->ai_family, t->ai_socktype, t->ai_protocol); 180 if (sockfd >= 0) { 181 if (!connect(sockfd, t->ai_addr, t->ai_addrlen)) 183 close(sockfd); 184 sockfd = -1; 191 if (sockfd < 0) { 199 if (write(sockfd, msg, sizeof msg) != sizeof msg) { 204 if (read(sockfd, msg, sizeof msg) != sizeof msg || 205 write(sockfd, "don 239 int sockfd = -1, connfd; local [all...] |
/freebsd-11-stable/tools/tools/vxge/ |
H A D | vxge_info.c | 36 static int sockfd; variable 106 sockfd = socket(AF_INET, SOCK_DGRAM, 0); 107 if (sockfd < 0) { 312 err = ioctl(sockfd, SIOCGPRIVATE_1, &ifr); 345 err = ioctl(sockfd, SIOCGPRIVATE_1, &ifr); 377 err = ioctl(sockfd, SIOCGPRIVATE_1, &ifr); 410 err = ioctl(sockfd, SIOCGPRIVATE_1, &ifr); 449 err = ioctl(sockfd, SIOCGPRIVATE_1, &ifr); 488 err = ioctl(sockfd, SIOCGPRIVATE_1, &ifr); 511 err = ioctl(sockfd, SIOCGPRIVATE_ [all...] |
/freebsd-11-stable/contrib/openbsm/bin/auditdistd/ |
H A D | proto_tls.c | 267 tls_loop(int sockfd, SSL *tcpssl) argument 277 FD_SET(sockfd, &fds); 279 maxfd = MAX(sockfd, tcpfd); 287 if (FD_ISSET(sockfd, &fds)) 288 tcp_recv_ssl_send(sockfd, tcpssl); 290 ssl_recv_tcp_send(tcpssl, sockfd); 344 int sockfd, tcpfd; local 354 sockfd = startfd; 410 nonblock(sockfd); 420 switch (send(sockfd, 569 int error, sockfd; local 655 int sockfd, tcpfd, ret; local 710 int startfd, sockfd, tcpfd, safefd; local [all...] |
/freebsd-11-stable/lib/libc/include/ |
H A D | nscachedcli.h | 63 int sockfd; member in struct:cached_connection_
|
/freebsd-11-stable/stand/libsa/ |
H A D | bootparam.c | 107 bp_whoami(int sockfd) argument 136 if (!(d = socktodesc(sockfd))) { 137 RPC_PRINTF(("bp_whoami: bad socket. %d\n", sockfd)); 235 bp_getfile(int sockfd, char *key, struct in_addr *serv_addr, char *pathname) argument 248 if (!(d = socktodesc(sockfd))) { 249 RPC_PRINTF(("bp_getfile: bad socket. %d\n", sockfd));
|
/freebsd-11-stable/tests/sys/kern/ |
H A D | unix_passfd_test.c | 144 sendfd_payload(int sockfd, int send_fd, void *payload, size_t paylen) argument 164 len = sendmsg(sockfd, &msghdr, 0); 170 sendfd(int sockfd, int send_fd) argument 176 len = sendfd_payload(sockfd, send_fd, &ch, sizeof(ch)); 183 localcreds(int sockfd) argument 189 rc = getsockopt(sockfd, 0, LOCAL_CREDS, &val, &sz); 196 recvfd_payload(int sockfd, int *recv_fd, void *buf, size_t buflen, argument 219 len = recvmsg(sockfd, &msghdr, 0); 241 ATF_REQUIRE_MSG(!localcreds(sockfd) || foundcreds, 246 recvfd(int sockfd, in argument 441 send_cmsg(int sockfd, void *cmsg, size_t cmsgsz) argument 466 recv_cmsg(int sockfd, char *cmsg, size_t cmsgsz, int flags) argument [all...] |
/freebsd-11-stable/lib/libc/net/ |
H A D | nscachedcli.c | 78 s_result = _sendto(connection->sockfd, data + result, 121 s_result = _read(connection->sockfd, data + result, 172 EV_SET(&eventlist, connection->sockfd, EVFILT_WRITE, EV_ADD, 179 result = (_sendmsg(connection->sockfd, &cred_hdr, 181 EV_SET(&eventlist, connection->sockfd, EVFILT_WRITE, EV_ADD, 222 retval->sockfd = client_socket; 227 EV_SET(&eventlist, retval->sockfd, EVFILT_WRITE, EV_ADD, 0, 0, NULL); 233 EV_SET(&eventlist, retval->sockfd, EVFILT_READ, EV_ADD, 0, 0, NULL); 244 _close(connection->sockfd);
|
/freebsd-11-stable/contrib/mdocml/ |
H A D | catman.c | 53 run_mandocd(int sockfd, const char *outtype, const char* defos) argument 57 if (snprintf(sockfdstr, sizeof(sockfdstr), "%d", sockfd) == -1)
|
/freebsd-11-stable/contrib/ntp/ntpdc/ |
H A D | ntpdc.c | 181 static SOCKET sockfd; /* fd socket is opened on */ variable 488 closesocket(sockfd); 518 sockfd = socket(ai->ai_family, SOCK_DGRAM, 0); 519 if (sockfd == INVALID_SOCKET) { 529 if (setsockopt(sockfd, SOL_SOCKET, SO_RCVBUF, 537 if (connect(sockfd, (struct sockaddr *)&hostaddr, 540 if (connect(sockfd, ai->ai_addr, ai->ai_addrlen) == -1) 565 if (send(sockfd, xdata, xdatalen, 0) == -1) { 646 FD_SET(sockfd, &fds); 647 n = select(sockfd [all...] |
/freebsd-11-stable/crypto/openssh/ |
H A D | sshconnect.c | 334 timeout_connect(int sockfd, const struct sockaddr *serv_addr, argument 345 result = connect(sockfd, serv_addr, addrlen); 349 set_nonblock(sockfd); 350 rc = connect(sockfd, serv_addr, addrlen); 352 unset_nonblock(sockfd); 361 fdset = xcalloc(howmany(sockfd + 1, NFDBITS), 363 FD_SET(sockfd, fdset); 367 rc = select(sockfd + 1, NULL, fdset, NULL, &tv); 385 if (getsockopt(sockfd, SOL_SOCKET, SO_ERROR, &optval, 395 unset_nonblock(sockfd); [all...] |