| /src/external/bsd/mdocml/dist/ |
| term_tag.h | 25 int ofd; /* Original output file descriptor. */ member in struct:tag_files
|
| term_tag.c | 54 int ofd; /* In /tmp/, dup(2)ed to stdout. */ local 57 ofd = tfd = -1; 81 if ((tag_files.ofd = dup(STDOUT_FILENO)) == -1) { 91 if ((ofd = mkstemps(tag_files.ofn, strlen(suffix))) == -1) { 100 ofd = open(outfilename, O_WRONLY | O_CREAT | O_EXCL, 0644); 101 if (ofd == -1) { 131 if (dup2(ofd, STDOUT_FILENO) == -1) { 135 close(ofd); 140 if (ofd != -1) 141 close(ofd); [all...] |
| /src/sys/arch/ews4800mips/stand/common/ |
| inckern.c | 41 FILE *ifd, *ofd; local 48 ofd = stdout; 63 if ((optarg == 0) || (ofd = fopen(optarg, "w")) == 0) 69 fprintf(ofd, "#include <lib/libsa/stand.h>\n"); 70 fprintf(ofd, "#include <lib/libkern/libkern.h>\n"); 71 fprintf(ofd, "#include \"local.h\"\n"); 72 fprintf(ofd, "uint8_t kernel_binary["); 74 fprintf(ofd, "%d];\n", total); 75 fprintf(ofd, "int kernel_binary_size = %d;\n", total); 77 fprintf(ofd, "] = {\n\t") [all...] |
| /src/games/hack/ |
| hack.save.c | 101 int fd, ofd; local 136 if ((ofd = open(lock, O_RDONLY)) < 0) { 145 getlev(ofd, hackpid, tmp); 146 (void) close(ofd);
|
| /src/sys/arch/macppc/stand/mkboothfs/ |
| mkboothfs.c | 69 int ofd; local 84 if ((ofd = open(boothfs, O_CREAT | O_TRUNC | O_WRONLY, 0644)) == -1) 101 write(ofd, buf, BSIZE); 122 write(ofd, buf, BSIZE); 132 write(ofd, buf, BSIZE); 138 write(ofd, buf, BSIZE); 144 write(ofd, buf, MACPPC_BOOT_BLOCK_MAX_SIZE); 151 if (write(ofd, buf, BOOTDATASIZE) != BOOTDATASIZE) 155 close(ofd);
|
| /src/tests/lib/libc/c063/ |
| t_renameat.c | 61 int ofd, nfd, fd; local 71 ATF_REQUIRE((ofd = open(ODIR, O_RDONLY, 0)) != -1); 73 ATF_REQUIRE(renameat(ofd, BASEFILE, nfd, BASETARGET) == 0); 74 ATF_REQUIRE(close(ofd) == 0);
|
| t_linkat.c | 63 int ofd, nfd, fd; local 71 ATF_REQUIRE((ofd = open(ODIR, O_RDONLY, 0)) != -1); 73 ATF_REQUIRE(linkat(ofd, BASEFILE, nfd, BASETARGET, 0) == 0); 74 ATF_REQUIRE(close(ofd) == 0); 149 int ofd, nfd, fd; local 158 ATF_REQUIRE((ofd = open(ODIR, O_RDONLY, 0)) != -1); 160 ATF_REQUIRE(linkat(ofd, BASELINK, nfd, BASETARGET, 162 ATF_REQUIRE(close(ofd) == 0); 182 int ofd, nfd, fd; local 191 ATF_REQUIRE((ofd = open(ODIR, O_RDONLY, 0)) != -1) [all...] |
| /src/external/gpl2/gettext/dist/gettext-tools/gnulib-lib/ |
| pipe.c | 139 int ofd[2]; local 154 if (_pipe (ofd, 4096, O_BINARY | O_NOINHERIT) < 0) 159 * parent -> ofd[1] -> ofd[0] -> child if pipe_stdin 178 if ((!pipe_stdin || dup2 (ofd[0], STDIN_FILENO) >= 0) 197 /* The child process doesn't inherit ifd[0], ifd[1], ofd[0], ofd[1], 219 close (ofd[0]); 230 close (ofd[1]); 237 fd[1] = ofd[1] [all...] |
| /src/sys/arch/pmax/stand/smallnet/setnetimage/ |
| setnetimage.c | 79 int ifd, ofd, i, nsegs; local 102 if ((ofd = open(bootfile, O_RDWR)) < 0) 108 if (fstat(ofd, &osb) == -1) 114 MAP_FILE | MAP_SHARED, ofd, 0)) == (void *)-1) 211 close(ofd);
|
| /src/usr.bin/split/ |
| split.c | 60 static int ifd = STDIN_FILENO, ofd = -1; /* Input/output file descriptors. */ variable 206 if (bigwrite(ofd, bfr, dist) != (size_t)dist) 217 if (bigwrite(ofd, 227 if (bigwrite(ofd, C, len) != (size_t)len) 235 if (bigwrite(ofd, bfr, len) != (size_t)len) 270 if (bigwrite(ofd, Cs, bcnt) != (size_t)bcnt) 281 if (bigwrite(ofd, Cs, bcnt) != (size_t)bcnt) 321 if (ofd == -1) { 324 } else if (close(ofd) != 0) 367 if ((ofd = open(fname, O_WRONLY | O_CREAT | O_TRUNC, DEFFILEMODE)) < 0 [all...] |
| /src/external/bsd/ipf/dist/samples/ |
| proxy.c | 142 int onoff, ofd, slen; local 161 ofd = socket(AF_INET, SOCK_DGRAM, 0); 166 (void) connect(ofd, (struct sockaddr *)&usin, sizeof(usin)); 168 (void) getsockname(ofd, (struct sockaddr *)&usin, &slen); 169 close(ofd); 172 if ((ofd = socket(AF_INET, SOCK_STREAM, 0)) == -1) 175 if (bind(ofd, (struct sockaddr *)&usin, sizeof(usin))) 178 if (getsockname(ofd, (struct sockaddr *)&usin, &slen)) 223 if (connect(ofd, (struct sockaddr *)&usin, sizeof(usin))) 226 relay(in, out, ofd); [all...] |
| /src/external/bsd/openpam/dist/lib/libpam/ |
| openpam_ttyconv.c | 106 prompt_tty(int ifd, int ofd, const char *message, char *response, int echo) 135 if (write(ofd, message, strlen(message)) < 0) { 188 write(ofd, " timed out", 10); 229 write(ofd, "\n", 1); 313 int ifd, ofd, ret; local 321 ofd = STDOUT_FILENO; 326 ofd = ifd; 328 ret = prompt_tty(ifd, ofd, message, response, echo);
|
| /src/lib/libedit/ |
| refresh.c | 544 wchar_t *ofd, *ols, *oe, *nfd, *nls, *ne; local 554 ofd = o; 566 while (ofd < o) { 589 if (*ofd == '\0' && *nfd == '\0') { 596 while ((o > ofd) && (n > nfd) && (*--o == *--n)) 610 * case 1: insert: scan from nfd to nls looking for *ofd 612 if (*ofd) { 613 for (c = *ofd, n = nfd; n < nls; n++) { 615 for (o = ofd, p = n; 627 osb = ofd; [all...] |
| /src/sys/arch/amiga/stand/bootblock/elf2bb/ |
| elf2bb.c | 94 int ifd, ofd; local 460 ofd = open(argv[1], O_CREAT|O_WRONLY, 0644); 461 if (ofd < 0) 464 if (write(ofd, buffer, bbsize) != bbsize)
|
| /src/tests/lib/libc/db/ |
| h_db.c | 93 static int ofd = STDOUT_FILENO; /* Standard output fd. */ variable 128 if ((ofd = open(optarg, 187 if (ofd == STDOUT_FILENO && (t = strchr(p, '\n')) != NULL) 207 if (write(ofd, p + 1, len - 1) != (ssize_t)len - 1 || 208 write(ofd, "\n", 1) != 1) 344 (void)close(ofd); 376 (void)write(ofd, data.data, data.size); 377 if (ofd == STDOUT_FILENO) 378 (void)write(ofd, "\n", 1); 385 if (ofd != STDOUT_FILENO [all...] |
| /src/usr.bin/gencat/ |
| gencat.c | 150 int ofd, ifd; local 173 ofd = STDOUT_FILENO; 175 ofd = open(catfile, O_WRONLY | O_CREAT | O_EXCL, 0666); 176 if (ofd < 0) { 178 if ((ofd = open(catfile, O_RDWR)) < 0) { 188 MCReadCat(ofd); 189 if (lseek(ofd, (off_t)0, SEEK_SET) == (off_t)-1) { 213 if (ftruncate(ofd, 0) != 0) { 219 MCWriteCat(ofd);
|
| /src/usr.bin/sdiff/ |
| sdiff.c | 100 int ifd, ofd; local 125 if ((ofd = mkstemp(target_file)) == -1) { 133 wcount = write(ofd, buf, (size_t)rcount); 145 close(ofd);
|
| /src/bin/rcp/ |
| rcp.c | 493 int exists, first, ofd; local 650 if ((ofd = open(np, O_WRONLY|O_CREAT, mode)) < 0) { 655 if ((bp = allocbuf(&buffer, ofd, BUFSIZ)) == NULL) { 656 (void)close(ofd); 691 result = write(ofd, cp, resid); 700 if (ftruncate(ofd, size)) 705 if (fchmod(ofd, omode)) 709 if (fchmod(ofd, omode & ~mask)) 715 if (futimes(ofd, tv) < 0) 719 (void)close(ofd); [all...] |
| /src/sys/arch/arc/jazz/ |
| fd.c | 821 struct fd_softc *ofd = fdc->sc_fd[fd->sc_drive ^ 1]; local 822 if (ofd && ofd->sc_flags & FD_MOTOR) { 823 callout_stop(&ofd->sc_motoroff_ch); 824 ofd->sc_flags &= ~(FD_MOTOR | FD_MOTOR_WAIT);
|
| /src/sys/dev/isa/ |
| fd.c | 1103 struct fd_softc *ofd = fdc->sc_fd[fd->sc_drive ^ 1]; local 1104 if (ofd && ofd->sc_flags & FD_MOTOR) { 1105 callout_stop(&ofd->sc_motoroff_ch); 1106 ofd->sc_flags &= ~(FD_MOTOR | FD_MOTOR_WAIT);
|
| /src/sys/net/ |
| if_gre.c | 1006 int fd, ofd, rc; local 1010 ofd = sc->sc_fd; 1028 if (ofd != -1 && fd_getfile(ofd) != NULL) 1029 fd_close(ofd);
|
| /src/usr.bin/mail/ |
| mime_attach.c | 398 int ofd; local 402 ofd = dup(0); /* save stdin */ 408 if (dup2(ofd, 0) == -1) /* restore stdin */ 410 (void)close(ofd); /* close the copy */
|
| /src/usr.bin/xlint/xlint/ |
| xlint.c | 525 int ifd, ofd; local 529 if ((ofd = open(dest, O_WRONLY | O_CREAT | O_TRUNC, 0666)) == -1) { 545 if (write(ofd, buf, (size_t)rlen) != rlen) { 552 (void)close(ofd);
|
| /src/external/bsd/nvi/dist/ipc/ |
| ip.h | 123 int ofd; /* Output file descriptor. */ member in struct:_ip_vi 137 int ofd; /* Output file descriptor. */ member in struct:_ip_vi_win
|
| /src/sbin/savecore/ |
| savecore.c | 647 int bounds, ifd, nr, nw, ofd, tryksyms; local 651 ofd = -1; 684 ofd = Create(path, S_IRUSR | S_IWUSR | S_IRGRP | S_IROTH); 685 fp = fdopen(ofd, "w"); 762 ofd = Create(path, S_IRUSR | S_IWUSR); 763 fp = fdopen(ofd, "w");
|