| /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/external/bsd/mdocml/dist/ |
| 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...] |
| term_tag.h | 25 int ofd; /* Original output file descriptor. */ member in struct:tag_files
|
| /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/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_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...] |
| 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);
|
| /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/nvi/dist/ipc/ |
| ipc_method.c | 87 ipviwin->ofd = ipvi->ofd; 113 if (sendmsg(ipvi->ofd, &mh, 0) == -1) 128 ipviwin->ofd = sockets[0]; 194 return vi_send(ipvi->ofd, NULL, &ipb); 205 return vi_send(ipvi->ofd, "1", &ipb); 217 return vi_send(ipvi->ofd, "12", &ipb); 229 return vi_send(ipvi->ofd, "a", &ipb); 244 return vi_send(ipvi->ofd, "a1", &ipb); 260 return vi_send(ipvi->ofd, "ab1", &ipb) [all...] |
| ip_send.c | 39 vi_send(int ofd, const char *fmt, IP_BUF *ipbp) 57 if (ofd == 0) { 116 if ((nw = write(ofd, p, n)) < 0)
|
| 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/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/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...] |
| relay.c | 31 int relay(ifd, ofd, rfd) 32 int ifd, ofd, rfd; 42 if (nfd < ofd) 43 nfd = ofd; 55 FD_SET(ofd, &wfds); 74 if (n && FD_ISSET(ofd, &wfds)) { 75 rw = write(ofd, iwt, iwh - iwt);
|
| /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/bin/ksh/ |
| io.c | 231 ksh_dup2(ofd, nfd, errok) 232 int ofd; 236 int ret = dup2(ofd, nfd); 272 restfd(fd, ofd) 273 int fd, ofd; 277 if (ofd < 0) /* original fd closed */ 279 else if (fd != ofd) { 280 ksh_dup2(ofd, fd, true); /* XXX: what to do if this fails? */ 281 close(ofd);
|
| /src/usr.sbin/lpr/lpd/ |
| printjob.c | 99 static int ofd; /* output filter file descriptor */ variable 312 (void)write(ofd, FF, strlen(FF)); 314 (void)write(ofd, TR, strlen(TR)); 561 (void)write(ofd, FF, strlen(FF)); 567 if (write(ofd, buf, n) != n) { 584 fo = ofd; 716 write(ofd, "\031\1", 2); 1019 (void)write(ofd, FF, strlen(FF)); 1022 (void)write(ofd, class, strlen(class)); 1023 (void)write(ofd, ":", 1) [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/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/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/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/external/bsd/ppp/dist/pppd/ |
| tty.c | 969 start_charshunt(int ifd, int ofd) 973 cpid = ppp_safe_fork(ifd, ofd, (log_to_fd >= 0? log_to_fd: 2)); 1018 * (We assume ofd >= ifd which is true the way this gets called. :-). 1021 charshunt(int ifd, int ofd, char *record_file) 1082 if (ifd >= FD_SETSIZE || ofd >= FD_SETSIZE || pty_master >= FD_SETSIZE) 1084 ifd, ofd, pty_master); 1104 if (ofd != ifd) { 1105 flags = fcntl(ofd, F_GETFL); 1107 || fcntl(ofd, F_SETFL, flags | O_NONBLOCK) == -1) 1124 nfds = (ofd > pty_master? ofd: pty_master) + 1 [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/bin/pax/ |
| buf_subs.c | 683 rd_wrfile(ARCHD *arcn, int ofd, off_t *left) 699 if (ofd < 0) 701 else if (fstat(ofd, &sb) == 0) { 725 if ((res = file_write(ofd,bufpt,cnt,&rem,&isem,sz,fnm)) <= 0) { 748 if (ofd >= 0 && isem && (arcn->sb.st_size > 0L)) { 749 if (file_flush(ofd, fnm, isem) < 0) {
|
| /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)
|