Home
last modified time | relevance | path

Searched refs:wfd (Results 1 – 25 of 35) sorted by relevance

12

/freebsd/usr.sbin/ppp/
H A Dserver.c104 if (wfd < 0) in server_Read()
107 close(wfd); in server_Read()
108 wfd = -1; in server_Read()
111 wfd = -1; in server_Read()
113 if (wfd >= 0) in server_Read()
126 wfd = -1; in server_Read()
141 wfd = -1; in server_Read()
151 close(wfd); in server_Read()
152 wfd = -1; in server_Read()
156 if (wfd >= 0) { in server_Read()
[all …]
/freebsd/sys/contrib/openzfs/tests/zfs-tests/tests/functional/cp_files/
H A Dseekflood.c131 int h = 0, i, j, rfd, wfd; in main() local
137 wfd = _open_file(i, 1); in main()
139 _write_file(i, wfd); in main()
141 close(wfd); in main()
145 wfd = _open_file(j, 1); in main()
147 _write_file(j, wfd); in main()
149 close(wfd); in main()
/freebsd/tests/sys/kern/pipe/
H A Dbig_pipe_test.c20 fd_set wfd; in write_frame() local
24 FD_ZERO(&wfd); in write_frame()
25 FD_SET(fd, &wfd); in write_frame()
26 i = select(fd+1, NULL, &wfd, NULL, NULL); in write_frame()
/freebsd/contrib/sendmail/src/
H A Dsfsasl.c574 int wfd;
612 where, rfd, wfd, err);
622 where, rfd, wfd);
651 FD_SET(wfd, &ssl_maskw);
656 ret = select(wfd + 1, NULL, &ssl_maskw, &ssl_maskx,
718 int r, rfd, wfd, try, ssl_err; local
746 wfd = SSL_get_wfd(so->con);
747 try = tls_retry(so->con, rfd, wfd, tlsstart,
844 int r, rfd, wfd, try, ssl_err; local
871 wfd = SSL_get_wfd(so->con);
[all …]
/freebsd/bin/cat/
H A Dcat.c382 int wfd; in in_kernel_copy() local
385 wfd = fileno(stdout); in in_kernel_copy()
389 ret = copy_file_range(rfd, NULL, wfd, NULL, SSIZE_MAX, 0); in in_kernel_copy()
399 int off, wfd; in raw_cat() local
405 wfd = fileno(stdout); in raw_cat()
407 if (fstat(wfd, &sbuf)) in raw_cat()
426 if ((nw = write(wfd, buf + off, (size_t)nr)) < 0) in raw_cat()
/freebsd/usr.sbin/bhyve/
H A Duart_backend.c53 int wfd; /* fd for writing, may be == rfd */ member
113 (void)write(tf->wfd, &wb, 1); in ttywrite()
274 sc->tty.wfd = STDOUT_FILENO; in uart_stdio_backend()
279 if (fcntl(sc->tty.wfd, F_SETFL, O_NONBLOCK) != 0) in uart_stdio_backend()
313 sc->tty.rfd = sc->tty.wfd = fd; in uart_tty_backend()
/freebsd/sbin/ipf/ipsend/
H A Dresend.c68 int fd, wfd = initdevice(dev, 5), len, i; in ip_resend() local
71 if (wfd == -1) in ip_resend()
124 if (sendip(wfd, (char *)eh, len) == -1) in ip_resend()
H A Dipsend.c122 int wfd; in send_packets() local
124 wfd = initdevice(dev, 5); in send_packets()
125 if (wfd == -1) in send_packets()
127 return (send_packet(wfd, mtu, ip, gwip)); in send_packets()
/freebsd/usr.sbin/rtsold/
H A Dcap_script.c89 int error, wfd; in cap_script_run() local
103 wfd = nvlist_take_descriptor(nvl, "fd"); in cap_script_run()
107 return (error == 0 ? wfd : -1); in cap_script_run()
H A Drtsol.c744 int status, wfd; in call_script() local
749 wfd = cap_script_run(capscript, argv); in call_script()
750 if (wfd == -1) { in call_script()
761 if (write(wfd, smp->sm_msg, len) != len) { in call_script()
770 (void)close(wfd); in call_script()
/freebsd/crypto/openssh/
H A Dchannels.c431 if (wfd != -1 && wfd != rfd) in channel_register_fds()
437 c->wfd = wfd; in channel_register_fds()
464 if (wfd != -1 && !isatty(wfd) && in channel_register_fds()
468 set_nonblock(wfd); in channel_register_fds()
479 if (wfd != -1) in channel_register_fds()
578 c->wfd = -1; in channel_close_fd()
603 int sock = c->sock, rfd = c->rfd, wfd = c->wfd, efd = c->efd; in channel_close_fds() local
608 if (wfd != sock && wfd != rfd) in channel_close_fds()
2749 if (c->wfd != -1 && c->rfd != c->wfd) { in channel_prepare_pollfd()
2890 if (c->rfd != -1 && c->wfd != -1 && c->rfd != c->wfd && in channel_after_poll()
[all …]
H A Dnchan.c382 c->self, c->istate, c->ostate, c->sock, c->wfd, c->efd, in chan_shutdown_write()
391 if (channel_close_fd(ssh, c, &c->wfd) < 0) { in chan_shutdown_write()
393 "fd %d [i%d o%d]: %.100s", c->self, c->wfd, in chan_shutdown_write()
H A Dchannels.h136 int wfd; /* write fd */ member
/freebsd/sbin/ipf/ipfs/
H A Dipfs.c373 int wfd = -1; in writestate() local
378 wfd = open(file, O_WRONLY|O_TRUNC|O_CREAT, 0600); in writestate()
379 if (wfd == -1) { in writestate()
402 close(wfd); in writestate()
407 if (write(wfd, ipsp, sizeof(ips)) != sizeof(ips)) { in writestate()
409 close(wfd); in writestate()
413 close(wfd); in writestate()
/freebsd/usr.bin/sed/
H A Dprocess.c478 if (cp->u.s->wfd == -1 && (cp->u.s->wfd = open(cp->u.s->wfile, in substitute()
481 if (write(cp->u.s->wfd, ps, psl) != (ssize_t)psl || in substitute()
482 write(cp->u.s->wfd, "\n", 1) != 1) in substitute()
773 if (cp->u.s->wfd != -1 && close(cp->u.s->wfd)) in cfclose()
775 cp->u.s->wfd = -1; in cfclose()
H A Ddefs.h65 int wfd; /* Cached file descriptor */ member
/freebsd/usr.sbin/usbdump/
H A Dusbdump.c83 int wfd; member
653 ret = write(p->wfd, &len, sizeof(int)); in write_packets()
658 ret = write(p->wfd, data, datalen); in write_packets()
758 p->wfd = open(w_arg, O_CREAT | O_TRUNC | O_WRONLY, S_IRUSR | S_IWUSR); in init_wfile()
759 if (p->wfd < 0) { in init_wfile()
767 ret = write(p->wfd, (const void *)&uf, sizeof(uf)); in init_wfile()
1027 if (p->wfd > 0) in main()
1028 close(p->wfd); in main()
/freebsd/usr.bin/script/
H A Dscript.c110 fd_set rfd, wfd; in main() local
300 FD_ZERO(&wfd); in main()
305 FD_SET(master, &wfd); in main()
318 n = pselect(master + 1, &rfd, &wfd, NULL, tvp, pselmask); in main()
349 if (n > 0 && FD_ISSET(master, &wfd)) { in main()
/freebsd/contrib/blocklist/diff/
H A Dproftpd.diff113 + else if (c->wfd != -1)
114 + fd = c->wfd;
/freebsd/share/examples/ipfilter/l4check/
H A Dl4check.c277 fd_set rfd, wfd; in runconfig() local
330 FD_ZERO(&wfd); in runconfig()
363 FD_SET(l4->l4_fd, &wfd); in runconfig()
371 i = select(mfd + 1, &rfd, &wfd, NULL, &tv); in runconfig()
390 if ((l4->l4_fd >= 0) && FD_ISSET(l4->l4_fd, &wfd)) { in runconfig()
/freebsd/contrib/nvi/common/
H A Dexf.c1027 int flags, maxnum, nr, num, nw, rfd, wfd, version; local
1034 rfd = wfd = -1;
1163 if ((wfd = open(wfname, flags | O_WRONLY, S_IRUSR | S_IWUSR)) < 0) {
1171 if ((nw = write(wfd, buf + off, nr)) < 0) {
1184 if (close(wfd)) {
1196 if (wfd != -1) {
1198 (void)close(wfd);
/freebsd/contrib/llvm-project/compiler-rt/lib/tsan/rtl/
H A Dtsan_fd.cpp271 void FdPipeCreate(ThreadState *thr, uptr pc, int rfd, int wfd) { in FdPipeCreate() argument
272 DPrintf("#%d: FdCreatePipe(%d, %d)\n", thr->tid, rfd, wfd); in FdPipeCreate()
275 init(thr, pc, wfd, ref(s)); in FdPipeCreate()
H A Dtsan_fd.h47 void FdPipeCreate(ThreadState *thr, uptr pc, int rfd, int wfd);
/freebsd/contrib/wpa/src/p2p/
H A Dp2p_sd.c19 static int wfd_wsd_supported(struct wpabuf *wfd) in wfd_wsd_supported() argument
25 if (wfd == NULL) in wfd_wsd_supported()
28 pos = wpabuf_head(wfd); in wfd_wsd_supported()
29 end = pos + wpabuf_len(wfd); in wfd_wsd_supported()
/freebsd/sys/contrib/openzfs/contrib/pyzfs/libzfs_core/
H A D_libzfs_core.py1870 (rfd, wfd) = os.pipe()
1872 fcntl.fcntl(wfd, fcntl.F_SETFD, fcntl.FD_CLOEXEC)
1874 options['fd'] = int32_t(wfd)
1880 return (rfd, wfd)

12