| /openbsd/src/sys/dev/microcode/bwi/extract/ |
| D | extract.c | 37 int i, fdin, fdout, nfiles; in main() local 47 if ((fdin = open(argv[1], O_RDONLY)) == -1) in main() 51 if (read(fdin, &nfiles, sizeof(nfiles)) < 1) in main() 65 if (read(fdin, h[i]->filename, sizeof(h[i]->filename)) < 1) in main() 67 if (read(fdin, &h[i]->filesize, sizeof(h[i]->filesize)) < 1) in main() 70 if (read(fdin, &h[i]->fileoffset, sizeof(h[i]->fileoffset)) < 1) in main() 82 if (lseek(fdin, h[i]->fileoffset, SEEK_SET) == -1) in main() 84 if (read(fdin, p, h[i]->filesize) < 1) in main() 100 close (fdin); in main()
|
| /openbsd/src/usr.bin/signify/ |
| D | zsig.c | 133 copy_blocks(int fdout, int fdin, const char *sha, const char *endsha, in copy_blocks() argument 156 ssize_t more = read(fdin, buffer+n, bufsize-n); in copy_blocks() 190 int fdin, fdout; in zverify() local 198 fdin = xopen(sigfile, O_RDONLY | O_NOFOLLOW, 0); in zverify() 200 bufend = readgz_header(&h, fdin); in zverify() 228 copy_blocks(fdout, fdin, p, h.endcomment, bufsize, bufend); in zverify() 231 close(fdin); in zverify() 239 int fdin, fdout; in zsign() local 250 fdin = xopen(msgfile, O_RDONLY, 0); in zsign() 251 if (fstat(fdin, &sb) == -1 || !S_ISREG(sb.st_mode)) in zsign() [all …]
|
| /openbsd/src/usr.sbin/nsd/ |
| D | popen3.c | 31 int fdin[] = { -1, -1 }; in popen3() local 43 if(fdinptr != NULL && pipe(fdin) == -1) { in popen3() 81 if(dup2(fdin[0], 0) == -1) { in popen3() 84 close_pipe(fdin); in popen3() 129 close(fdin[0]); in popen3() 130 *fdinptr = fdin[1]; in popen3() 146 close_pipe(fdin); in popen3()
|
| D | verify.c | 419 int fdin, fderr, fdout, flags; in verify_zone() local 426 fdin = fdout = fderr = -1; in verify_zone() 458 fdin = zone->opts->pattern->verifier_feed_zone ? -2 : -1; in verify_zone() 460 fdin = nsd->options->verifier_feed_zone ? -2 : -1; in verify_zone() 466 setenv("VERIFY_ZONE_ON_STDIN", fdin == -2 ? "yes" : "no", 1); in verify_zone() 469 command, fdin == -2 ? &fdin : NULL, &fdout, &fderr); in verify_zone() 489 if (fdin >= 0) { in verify_zone() 490 if ((fin = fdopen(fdin, "w")) == NULL) { in verify_zone() 608 } else if (fdin >= 0) { in verify_zone() 609 close(fdin); in verify_zone()
|
| /openbsd/src/usr.bin/rsync/ |
| D | server.c | 55 int fdin = STDIN_FILENO, in rsync_server() local 67 if (!fcntl_nonblock(fdin) || in rsync_server() 78 if (!io_read_int(&sess, fdin, &sess.rver)) { in rsync_server() 123 if (!rsync_sender(&sess, fdin, fdout, argc, argv)) { in rsync_server() 144 if (!rsync_receiver(&sess, fdin, fdout, argv[1])) { in rsync_server() 152 if (io_read_check(&sess, fdin)) in rsync_server()
|
| D | downloader.c | 67 int fdin; /* read descriptor from sender */ member 174 download_alloc(struct sess *sess, int fdin, in download_alloc() argument 188 p->fdin = fdin; in download_alloc() 314 if (!io_read_int(sess, p->fdin, &idx)) { in rsync_downloader() 337 if (!blk_send_ack(sess, p->fdin, &p->blk)) { in rsync_downloader() 453 assert(p->fdin != -1); in rsync_downloader() 455 if (!io_read_int(sess, p->fdin, &rawtok)) { in rsync_downloader() 466 if (!io_read_buf(sess, p->fdin, buf, sz)) { in rsync_downloader() 481 if ((c = io_read_check(p->fdin)) < 0) { in rsync_downloader() 519 if ((c = io_read_check(p->fdin)) < 0) { in rsync_downloader() [all …]
|
| D | receiver.c | 173 rsync_receiver(struct sess *sess, int fdin, int fdout, const char *root) in rsync_receiver() argument 232 recv_rules(sess, fdin); in rsync_receiver() 239 if (!flist_recv(sess, fdin, &fl, &flsz)) { in rsync_receiver() 246 if (!io_read_int(sess, fdin, &ioerror)) { in rsync_receiver() 297 pfd[PFD_SENDER_IN].fd = fdin; in rsync_receiver() 315 dl = download_alloc(sess, fdin, fl, flsz, dfd); in rsync_receiver() 352 if (!io_read_flush(sess, fdin)) { in rsync_receiver() 417 if (!io_read_int(sess, fdin, &ioerror)) { in rsync_receiver() 439 if (!sess_stats_recv(sess, fdin)) { in rsync_receiver()
|
| D | sender.c | 356 rsync_sender(struct sess *sess, int fdin, in rsync_sender() argument 404 if (!flist_send(sess, fdin, fdout, fl, flsz)) { in rsync_sender() 427 recv_rules(sess, fdin); in rsync_sender() 447 pfd[0].fd = fdin; in rsync_sender() 473 if (!io_read_flush(sess, fdin)) { in rsync_sender() 477 c = io_read_check(fdin); in rsync_sender() 495 if (!io_read_int(sess, fdin, &idx)) { in rsync_sender() 500 &sdlq, idx, fl, flsz, fdin)) { in rsync_sender() 504 c = io_read_check(fdin); in rsync_sender() 665 if (!io_read_int(sess, fdin, &idx)) { in rsync_sender()
|
| D | flist.c | 256 flist_send(struct sess *sess, int fdin, int fdout, const struct flist *fl, in flist_send() argument 285 io_read_check(fdin) && in flist_send() 286 !io_read_flush(sess, fdin)) { in flist_send()
|
| /openbsd/src/sys/dev/microcode/bwi/build/ |
| D | build.c | 44 int fdout, fdin; in main() local 127 if ((fdin = open(h[i].filename, O_RDONLY)) == -1) { in main() 135 close(fdin); in main() 138 if (read(fdin, p, h[i].filesize) < 1) { in main() 142 close(fdin); in main() 149 close(fdin); in main() 153 close(fdin); in main()
|
| /openbsd/src/regress/sys/kern/sosplice/perf/ |
| D | relay.c | 68 relay_copy(int fdin, int fdout) in relay_copy() argument 78 nr = read(fdin, buf, sizeof(buf)); in relay_copy() 97 relay_splice(int fdin, int fdout) in relay_splice() argument 105 if (setsockopt(fdin, SOL_SOCKET, SO_SPLICE, &fdout, sizeof(int)) == -1) in relay_splice() 108 FD_SET(fdin, &fdset); in relay_splice() 109 if (select(fdin+1, &fdset, NULL, NULL, NULL) == -1) in relay_splice() 112 if (getsockopt(fdin, SOL_SOCKET, SO_ERROR, &error, &optlen) == -1) in relay_splice() 117 if (getsockopt(fdin, SOL_SOCKET, SO_SPLICE, &len, &optlen) == -1) in relay_splice()
|
| /openbsd/src/usr.sbin/smtpd/ |
| D | queue_backend.c | 287 int fdin = -1, fdout = -1, fd = -1; in queue_message_fd_r() local 292 fdin = handler_message_fd_r(msgid); in queue_message_fd_r() 296 "queue-backend: queue_message_fd_r(%08"PRIx32") -> %d", msgid, fdin); in queue_message_fd_r() 298 if (fdin == -1) in queue_message_fd_r() 306 if ((ifp = fdopen(fdin, "r")) == NULL) in queue_message_fd_r() 308 fdin = fd; in queue_message_fd_r() 320 lseek(fdin, SEEK_SET, 0); in queue_message_fd_r() 328 if ((ifp = fdopen(fdin, "r")) == NULL) in queue_message_fd_r() 330 fdin = fd; in queue_message_fd_r() 342 lseek(fdin, SEEK_SET, 0); in queue_message_fd_r() [all …]
|
| /openbsd/src/usr.bin/calendar/ |
| D | io.c | 316 int pdes[2], fdin; in opencal() local 320 if ((fdin = open(calendarFile, O_RDONLY)) == -1 || in opencal() 321 fstat(fdin, &st) == -1 || !S_ISREG(st.st_mode)) { in opencal() 328 (fdin = open(calendarFile, O_RDONLY)) != -1)) in opencal() 335 close(fdin); in opencal() 342 close(fdin); in opencal() 345 dup2(fdin, STDIN_FILENO); in opencal()
|
| /openbsd/src/usr.bin/mail/ |
| D | tty.c | 48 int fdin; member 96 tty.fdin = fileno(stdin); in grabh() 98 if (tcgetattr(tty.fdin, &oldtio) == -1) { in grabh() 110 if (tcsetattr(tty.fdin, TCSADRAIN, &newtio) == -1) { in grabh() 159 if (tcsetattr(tty.fdin, TCSADRAIN, &oldtio) == -1) in grabh() 330 n = read(t->fdin, &c, 1); in tty_getc()
|
| /openbsd/src/gnu/usr.bin/cvs/emx/ |
| D | filesubr.c | 43 int fdin, fdout; local 55 if ((fdin = open (from, O_RDONLY | O_BINARY)) < 0) 57 if (fstat (fdin, &sb) < 0) 69 n = read (fdin, buf, sizeof(buf)); 92 if (close (fdin) < 0)
|
| /openbsd/src/gnu/usr.bin/cvs/os2/ |
| D | filesubr.c | 37 int fdin, fdout; local 49 if ((fdin = open (from, O_RDONLY | O_BINARY)) < 0) 51 if (fstat (fdin, &sb) < 0) 63 n = read (fdin, buf, sizeof(buf)); 86 if (close (fdin) < 0)
|
| /openbsd/src/gnu/usr.bin/cvs/windows-NT/ |
| D | filesubr.c | 41 int fdin, fdout; local 53 if ((fdin = open (from, O_RDONLY | O_BINARY)) < 0) 55 if (fstat (fdin, &sb) < 0) 67 n = read (fdin, buf, sizeof(buf)); 90 if (close (fdin) < 0)
|
| /openbsd/src/gnu/usr.bin/cvs/vms/ |
| D | filesubr.c | 34 int fdin, fdout; local 59 if ((fdin = open (from, O_RDONLY)) < 0) 61 if (fstat (fdin, &sb) < 0) 72 n = read (fdin, buf, sizeof(buf)); 95 if (close (fdin) < 0)
|
| /openbsd/src/gnu/usr.bin/cvs/src/ |
| D | filesubr.c | 35 int fdin, fdout; local 66 if ((fdin = open (from, O_RDONLY)) < 0) 68 if (fstat (fdin, &sb) < 0) 79 n = read (fdin, buf, sizeof(buf)); 102 if (close (fdin) < 0)
|
| /openbsd/src/sys/dev/isa/ |
| D | fdreg.h | 59 #define fdin 0 /* Digital Input Register (R) */ macro
|
| /openbsd/src/bin/csh/ |
| D | file.c | 72 int fdin; member 167 n = read(cl->fdin, &c, 1); in cl_getc() 376 ioctl(cl->fdin, TIOCSTAT); in cl_status() 776 cl.fdin = SHIN; in tenex()
|
| /openbsd/src/usr.bin/ssh/ |
| D | scp.c | 254 char *cmd, int *fdin, int *fdout, pid_t *pid) in do_cmd() argument 310 *fdin = sv[1]; in do_cmd() 326 int fdin, int fdout) in do_cmd2() argument 343 if (dup2(fdin, 0) == -1) in do_cmd2()
|
| D | session.c | 1914 int fdin, int fdout, int fderr, int ignore_fderr, int is_tty) in session_set_fds() argument 1923 fdout, fdin, fderr, in session_set_fds()
|
| /openbsd/src/gnu/llvm/compiler-rt/include/sanitizer/ |
| D | linux_syscall_hooks.h | 1692 #define __sanitizer_syscall_pre_tee(fdin, fdout, len, flags) \ argument 1693 __sanitizer_syscall_pre_impl_tee((long)(fdin), (long)(fdout), (long)(len), \ 1695 #define __sanitizer_syscall_post_tee(res, fdin, fdout, len, flags) \ argument 1696 __sanitizer_syscall_post_impl_tee(res, (long)(fdin), (long)(fdout), \ 2984 void __sanitizer_syscall_pre_impl_tee(long fdin, long fdout, long len, 2986 void __sanitizer_syscall_post_impl_tee(long res, long fdin, long fdout,
|
| /openbsd/src/gnu/llvm/compiler-rt/lib/sanitizer_common/ |
| D | sanitizer_common_syscalls.inc | 2908 PRE_SYSCALL(tee)(long fdin, long fdout, long len, long flags) {} 2910 POST_SYSCALL(tee)(long res, long fdin, long fdout, long len, long flags) {}
|