Home
last modified time | relevance | path

Searched refs:outfd (Results 1 – 15 of 15) sorted by relevance

/dragonfly/usr.sbin/daemon/
H A Ddaemon.c62 int outfd; member
87 int pfd[2] = { -1, -1 }, outfd = -1; in main() local
173 if (outfd == -1) in main()
270 logpar.outfd = outfd; in main()
371 if (logpar.outfd > 0) in main()
372 close(logpar.outfd); in main()
374 logpar.outfd = open(outfn, O_CREAT | in main()
379 if (logpar.outfd == -1) { in main()
420 close(outfd); in main()
571 if (logpar->outfd != -1) { in do_output()
[all …]
/dragonfly/usr.sbin/pw/
H A Dcpdir.c55 int infd, outfd; in copymkdir() local
93 …} else if (S_ISREG(st.st_mode) && (outfd = open(dst, O_RDWR | O_CREAT | O_EXCL, st.st_mode)) != -1… in copymkdir()
95 close(outfd); in copymkdir()
106 write(outfd, copybuf, b); in copymkdir()
111 fchown(outfd, uid, gid); in copymkdir()
112 fchflags(outfd, st.st_flags); in copymkdir()
113 close(outfd); in copymkdir()
H A Dfileupd.c87 int outfd; in fileupdate() local
92 outfd = open(file, O_RDWR | O_CREAT | O_TRUNC, fmode); in fileupdate()
93 if (outfd == -1) in fileupdate()
96 FILE *outfp = fdopen(outfd, "w+"); in fileupdate()
100 close(outfd); in fileupdate()
H A Dedgroup.c74 int outfd; in editgroups() local
76 if ((outfd = open(grouptmp, O_RDWR | O_CREAT | O_TRUNC, 0644)) != -1) { in editgroups()
79 if ((outfp = fdopen(outfd, "w+")) == NULL) in editgroups()
80 close(outfd); in editgroups()
/dragonfly/usr.bin/mail/
H A Dpopen.c206 run_command(char *cmd, sigset_t *mask, int infd, int outfd, char *a0, char *a1, in run_command() argument
211 if ((pid = start_command(cmd, mask, infd, outfd, a0, a1, a2)) < 0) in run_command()
218 start_command(char *cmd, sigset_t *mask, int infd, int outfd, char *a0, in start_command() argument
235 prepare_child(mask, infd, outfd); in start_command()
244 prepare_child(sigset_t *nset, int infd, int outfd) in prepare_child() argument
255 if (outfd >= 0) in prepare_child()
256 dup2(outfd, 1); in prepare_child()
/dragonfly/games/mille/
H A Dsave.c61 int outfd; in save() local
113 if ((outfd = creat(buf, 0644)) < 0) { in save()
120 rv = varpush(outfd, writev); in save()
121 close(outfd); in save()
/dragonfly/contrib/binutils-2.34/libiberty/
H A Dsimple-object.c330 int outfd; in simple_object_copy_lto_debug_sections() local
356 outfd = open (dest, O_CREAT|O_WRONLY|O_TRUNC|O_BINARY, 00777); in simple_object_copy_lto_debug_sections()
357 if (outfd == -1) in simple_object_copy_lto_debug_sections()
364 errmsg = simple_object_write_to_file (dest_sobj, outfd, err); in simple_object_copy_lto_debug_sections()
365 close (outfd); in simple_object_copy_lto_debug_sections()
/dragonfly/contrib/gcc-8.0/libiberty/
H A Dsimple-object.c308 int outfd; in simple_object_copy_lto_debug_sections() local
333 outfd = open (dest, O_CREAT|O_WRONLY|O_TRUNC|O_BINARY, 00777); in simple_object_copy_lto_debug_sections()
334 if (outfd == -1) in simple_object_copy_lto_debug_sections()
341 errmsg = simple_object_write_to_file (dest_sobj, outfd, err); in simple_object_copy_lto_debug_sections()
342 close (outfd); in simple_object_copy_lto_debug_sections()
/dragonfly/usr.sbin/edquota/
H A Dedquota.c468 writeprivs(struct quotause *quplist, int outfd, char *name, int quotatype) in writeprivs() argument
473 ftruncate(outfd, 0); in writeprivs()
474 lseek(outfd, 0, L_SET); in writeprivs()
475 if ((fd = fdopen(dup(outfd), "w")) == NULL) in writeprivs()
606 writetimes(struct quotause *quplist, int outfd, int quotatype) in writetimes() argument
611 ftruncate(outfd, 0); in writetimes()
612 lseek(outfd, 0, L_SET); in writetimes()
613 if ((fd = fdopen(dup(outfd), "w")) == NULL) in writetimes()
/dragonfly/contrib/bmake/
H A Dmeta.c1680 int outfd, metafd, maxfd, nfds; in meta_compat_parent() local
1686 outfd = childPipe[0]; in meta_compat_parent()
1693 if (outfd > maxfd) in meta_compat_parent()
1694 maxfd = outfd; in meta_compat_parent()
1698 while (outfd != -1 || metafd != -1) { in meta_compat_parent()
1700 if (outfd != -1) { in meta_compat_parent()
1701 FD_SET(outfd, &readfds); in meta_compat_parent()
1713 if (outfd != -1 && FD_ISSET(outfd, &readfds) != 0) do { in meta_compat_parent()
1715 ssize_t nread = read(outfd, buf, sizeof buf - 1); in meta_compat_parent()
1719 close(outfd); in meta_compat_parent()
[all …]
/dragonfly/usr.sbin/dconschat/
H A Ddconschat.c117 int outfd; member
510 p->infd = p->outfd = -1; in dconschat_init_socket()
519 p->outfd = STDOUT_FILENO; in dconschat_init_socket()
603 p->infd = p->outfd = ns; in dconschat_accept_socket()
707 close(p->outfd); in dconschat_read_socket()
712 p->infd = p->outfd = -1; in dconschat_read_socket()
755 dconschat_write_socket(p->outfd, buf, len); in dconschat_proc_dcons()
/dragonfly/contrib/cryptsetup/lib/
H A Dutils.c350 int infd = STDIN_FILENO, outfd; in interactive_pass() local
356 if ((infd = outfd = open("/dev/tty", O_RDWR)) == -1) { in interactive_pass()
358 outfd = STDERR_FILENO; in interactive_pass()
367 if (write(outfd, prompt, strlen(prompt)) < 0) in interactive_pass()
378 if (!failed && write(outfd, "\n", 1)); in interactive_pass()
/dragonfly/contrib/less/
H A Doutput.c84 static int outfd = 2; /* stderr */ variable
391 if (write(outfd, obuf, n) != n) in flush()
401 outfd = fd; in set_output()
/dragonfly/usr.sbin/lpr/lpd/
H A Dprintjob.c1207 execfilter(struct printer *pp, char *f_cmd, char *f_av[], int infd, int outfd) in execfilter() argument
1273 dup2(outfd, 1); in execfilter()
/dragonfly/contrib/tnftp/src/
H A Dftp.c617 copy_bytes(int infd, int outfd, char *buf, size_t bufsize, in copy_bytes() argument
655 outc = write(outfd, bufp, inc); in copy_bytes()