Searched refs:sfd (Results 1 - 20 of 20) sorted by relevance

/freebsd-11-stable/contrib/blacklist/test/
H A Dsrvtest.c104 int sfd; local
107 sfd = socket(af == AF_INET ? PF_INET : PF_INET6, type, 0);
108 if (sfd == -1)
128 if (bind(sfd, (const void *)&ss, slen) == -1)
132 if (listen(sfd, 5) == -1)
134 return sfd;
138 handle(int type, int sfd) argument
145 if ((afd = accept(sfd, (void *)&ss, &alen)) == -1)
148 afd = sfd;
H A Dcltest.c93 int sfd; local
124 if ((sfd = socket(AF_INET, type, 0)) == -1)
129 if (connect(sfd, (const void *)&ss, slen) == -1)
133 if (write(sfd, msg, len) != (ssize_t)len)
/freebsd-11-stable/contrib/ipfilter/ipsend/
H A Darp.c67 static int sfd = -1; local
95 if (sfd == -1)
96 if ((sfd = socket(AF_INET, SOCK_DGRAM, 0)) == -1)
102 if (ioctl(sfd, SIOCGARP, (caddr_t)&ar) == -1)
/freebsd-11-stable/sbin/ggate/ggatec/
H A Dggatec.c270 int sfd; local
283 sfd = socket(AF_INET, SOCK_STREAM, 0);
284 if (sfd == -1) {
290 g_gate_socket_settings(sfd);
292 if (connect(sfd, (struct sockaddr *)&serv, sizeof(serv)) == -1) {
295 close(sfd);
310 if (g_gate_send(sfd, &ver, sizeof(ver), MSG_NOSIGNAL) == -1) {
313 close(sfd);
317 if (g_gate_recv(sfd, &ver, sizeof(ver), MSG_WAITALL) == -1) {
320 close(sfd);
[all...]
/freebsd-11-stable/sbin/ggate/ggated/
H A Dggated.c434 connection_new(struct g_gate_cinit *cinit, struct sockaddr *s, int sfd) argument
460 conn->c_sendfd = sfd;
462 conn->c_recvfd = sfd;
475 struct sockaddr *s, int sfd)
487 conn->c_sendfd = sfd;
495 conn->c_recvfd = sfd;
504 * connection if sfd == -1.
588 sendfail(int sfd, int error, const char *fmt, ...) argument
596 data = g_gate_send(sfd, &sinit, sizeof(sinit), 0);
835 handshake(struct sockaddr *from, int sfd) argument
474 connection_add(struct ggd_connection *conn, struct g_gate_cinit *cinit, struct sockaddr *s, int sfd) argument
959 int ch, sfd, tmpsfd; local
[all...]
/freebsd-11-stable/crypto/heimdal/kadmin/
H A Dkadmind.c97 krb5_socket_t sfd = rk_INVALID_SOCKET; local
171 mini_inetd(debug_port, &sfd);
192 sfd = STDIN_FILENO;
198 kadmind_loop(context, keytab, sfd);
/freebsd-11-stable/sbin/ggate/shared/
H A Dggate.c278 g_gate_socket_settings(int sfd) argument
286 if (setsockopt(sfd, IPPROTO_TCP, TCP_NODELAY, &on,
291 if (setsockopt(sfd, SOL_SOCKET, SO_REUSEADDR, &on, sizeof(on)) == -1)
294 if (setsockopt(sfd, SOL_SOCKET, SO_RCVBUF, &bsize, sizeof(bsize)) == -1)
297 if (setsockopt(sfd, SOL_SOCKET, SO_SNDBUF, &bsize, sizeof(bsize)) == -1)
301 if (setsockopt(sfd, SOL_SOCKET, SO_SNDTIMEO, &tv, sizeof(tv)) == -1) {
305 if (setsockopt(sfd, SOL_SOCKET, SO_RCVTIMEO, &tv, sizeof(tv)) == -1) {
H A Dggate.h111 void g_gate_socket_settings(int sfd);
/freebsd-11-stable/contrib/ofed/librdmacm/
H A Dpreload.c447 static int copysockopts(int dfd, int sfd, struct socket_calls *dapi, argument
453 ret = sapi->fcntl(sfd, F_GETFL);
460 ret = sapi->getsockopt(sfd, SOL_SOCKET, SO_REUSEADDR, &param, &len);
467 ret = sapi->getsockopt(sfd, IPPROTO_TCP, TCP_NODELAY, &param, &len);
482 int sfd, dfd, param, ret; local
485 sfd = fd_getd(socket);
494 ret = sapi->getsockname(sfd, NULL, &len);
503 ret = copysockopts(dfd, sfd, dapi, sapi);
630 int sfd, dfd, ret; local
635 sfd
680 int lfd, sfd, dfd, ret, param; local
[all...]
/freebsd-11-stable/sbin/swapon/
H A Dswapon.c458 FILE *sfd; local
467 sfd = NULL;
517 sfd = fdopen(fd, "r");
518 if (sfd == NULL) {
523 p = fgetln(sfd, &linelen);
578 sfd = fdopen(fd, "r");
579 if (sfd == NULL) {
584 p = fgetln(sfd, &linelen);
637 if (sfd != NULL)
638 fclose(sfd);
[all...]
/freebsd-11-stable/contrib/netbsd-tests/lib/libc/ttyio/
H A Dt_ptm.c91 REQUIRE_ERRNO(fstat(ptm.sfd, &stm), -1);
101 (void)close(ptm.sfd);
/freebsd-11-stable/contrib/netbsd-tests/fs/ptyfs/
H A Dt_nullpts.c114 rump_sys_close(ptg.sfd);
/freebsd-11-stable/sbin/mdmfs/
H A Dmdmfs.c455 FILE *sfd; local
483 sfd = fdopen(fd, "r");
484 if (sfd == NULL)
486 linep = fgetln(sfd, &linelen);
502 fclose(sfd);
/freebsd-11-stable/contrib/ipfilter/tools/
H A Dipfs.c437 int sfd = -1, i; local
443 sfd = open(file, O_RDONLY, 0600);
444 if (sfd == -1) {
456 i = read(sfd, &ips, sizeof(ips));
503 close(sfd);
543 if (sfd != -1)
544 close(sfd);
/freebsd-11-stable/usr.sbin/bhyve/
H A Drfb.c86 int sfd; member in struct:rfb_softc
937 cfd = accept(rc->sfd, NULL, NULL);
1007 rc->sfd = socket(ai->ai_family, ai->ai_socktype, 0);
1008 if (rc->sfd < 0) {
1014 setsockopt(rc->sfd, SOL_SOCKET, SO_REUSEADDR, &on, sizeof(on));
1016 if (bind(rc->sfd, ai->ai_addr, ai->ai_addrlen) < 0) {
1022 if (listen(rc->sfd, 1) < 0) {
1030 if (cap_rights_limit(rc->sfd, &rights) == -1 && errno != ENOSYS)
/freebsd-11-stable/usr.sbin/lpr/lpd/
H A Dprintjob.c1008 int copycnt, filtstat, narg, resp, sfd, sfres, sizerr, statrc; local
1019 sfd = open(file, O_RDONLY);
1020 if (sfd < 0) {
1030 if ((stb.st_mode & S_IFMT) == S_IFLNK && fstat(sfd, &stb) == 0 &&
1032 close(sfd);
1106 filtstat = execfilter(pp, filtcmd, av, sfd, tfd);
1133 close(sfd);
1134 sfd = tfd;
1135 lseek(sfd, 0, SEEK_SET);
1176 if (sizerr == 0 && read(sfd, bu
[all...]
/freebsd-11-stable/contrib/groff/font/devps/generate/
H A DMakefile204 freeeuro.afm freeeuro.pfa: generate/freeeuro.sfd
205 pfaedit -script generate/sfdtopfa.pe generate/freeeuro.sfd
/freebsd-11-stable/usr.bin/tip/tip/
H A Dtip.h255 EXTERN int sfd; /* for ~< operation */ variable
H A Dcmds.c89 if ((sfd = creat(cp, 0666)) < 0) {
101 transfer(buf, sfd, value(EOFREAD));
/freebsd-11-stable/contrib/sendmail/src/
H A Dmap.c4837 SM_FILE_T *sfd; local
4861 sfd = safefopen(ldapmap_dequote(lmap->ldap_secret),
4863 if (sfd == NULL)
4870 sfd, TimeOuts.to_fileopen,
4872 (void) sm_io_close(sfd, SM_TIME_DEFAULT);

Completed in 200 milliseconds