HomeSort by: relevance | last modified time | path
    Searched defs:fds (Results 1 - 25 of 74) sorted by relevancy

1 2 3

  /src/distrib/utils/sparkcrc/
sparkcrc.c 84 FILE *fds; local in function:main
93 if (!(fds = fopen(argv[1], "r")))
95 while ((len = fread(buf, 1, sizeof(buf), fds)))
99 fclose(fds);
sparkcrc.c 84 FILE *fds; local in function:main
93 if (!(fds = fopen(argv[1], "r")))
95 while ((len = fread(buf, 1, sizeof(buf), fds)))
99 fclose(fds);
  /src/regress/sys/kern/dislodgefd/
dislodgefd.c 40 int fds[2]; variable in typeref:typename:int[2]
49 if (read(fds[0], buf, sizeof(buf)) == -1)
62 if (pipe(fds))
65 if (socketpair(PF_LOCAL, SOCK_STREAM, 0, fds) < 0)
75 close(fds[0]);
dislodgefd.c 40 int fds[2]; variable in typeref:typename:int[2]
49 if (read(fds[0], buf, sizeof(buf)) == -1)
62 if (pipe(fds))
65 if (socketpair(PF_LOCAL, SOCK_STREAM, 0, fds) < 0)
75 close(fds[0]);
  /src/games/sail/
dr_main.c 135 int fds[2]; local in function:startdriver
138 if (pipe(fds)) {
146 close(fds[0]);
147 driver_wait_fd = fds[1];
152 close(fds[0]);
153 close(fds[1]);
158 close(fds[1]);
159 read(fds[0], &c, 1);
160 close(fds[0]);
dr_main.c 135 int fds[2]; local in function:startdriver
138 if (pipe(fds)) {
146 close(fds[0]);
147 driver_wait_fd = fds[1];
152 close(fds[0]);
153 close(fds[1]);
158 close(fds[1]);
159 read(fds[0], &c, 1);
160 close(fds[0]);
  /src/tests/kernel/kqueue/read/
t_pipe.c 55 int fds[2]; local in function:ATF_TC_BODY
58 RL(pipe(fds));
61 EV_SET(&event[0], fds[0], EVFILT_READ, EV_ADD|EV_ENABLE, 0, 0, 0);
65 RL(write(fds[1], "foo", 3));
72 RL(n = read(fds[0], buffer, event[0].data));
t_pipe.c 55 int fds[2]; local in function:ATF_TC_BODY
58 RL(pipe(fds));
61 EV_SET(&event[0], fds[0], EVFILT_READ, EV_ADD|EV_ENABLE, 0, 0, 0);
65 RL(write(fds[1], "foo", 3));
72 RL(n = read(fds[0], buffer, event[0].data));
  /src/regress/sys/kern/latency1/
latency1.c 54 int fds[2]; variable in typeref:typename:int[2]
75 if (read(fds[0], buf, sizeof(buf)) == -1) {
100 if (pipe(fds)) {
136 if (write(fds[1], buf, sizeof(buf)) == -1) {
latency1.c 54 int fds[2]; variable in typeref:typename:int[2]
75 if (read(fds[0], buf, sizeof(buf)) == -1) {
100 if (pipe(fds)) {
136 if (write(fds[1], buf, sizeof(buf)) == -1) {
  /src/sys/modules/examples/pollpal/
cmd_pollpal.c 76 struct pollfd fds; local in function:main
87 fds.fd = fd;
88 fds.events = POLLOUT|POLLIN;
92 ret = poll(&fds, 1, TIMEOUT);
105 if (fds.revents & (POLLERR | POLLHUP | POLLNVAL))
108 if (fds.revents & POLLOUT) {
118 if (fds.revents & POLLIN) {
cmd_pollpal.c 76 struct pollfd fds; local in function:main
87 fds.fd = fd;
88 fds.events = POLLOUT|POLLIN;
92 ret = poll(&fds, 1, TIMEOUT);
105 if (fds.revents & (POLLERR | POLLHUP | POLLNVAL))
108 if (fds.revents & POLLOUT) {
118 if (fds.revents & POLLIN) {
  /src/tests/kernel/kqueue/write/
t_pipe.c 59 int fds[2]; local in function:ATF_TC_BODY
62 RL(pipe(fds));
64 RL(close(fds[0]));
66 EV_SET(&event[0], fds[1], EVFILT_WRITE, EV_ADD|EV_ENABLE, 0, 0, 0);
83 int fds[2]; local in function:ATF_TC_BODY
88 RL(pipe(fds));
91 EV_SET(&event[0], fds[1], EVFILT_WRITE, EV_ADD|EV_ENABLE, 0, 0, 0);
97 int sz = read(fds[0], buffer, 128);
108 RL(n = write(fds[1], "foo", 3));
109 RL(close(fds[1]))
124 int fds[2]; local in function:ATF_TC_BODY
    [all...]
t_pipe.c 59 int fds[2]; local in function:ATF_TC_BODY
62 RL(pipe(fds));
64 RL(close(fds[0]));
66 EV_SET(&event[0], fds[1], EVFILT_WRITE, EV_ADD|EV_ENABLE, 0, 0, 0);
83 int fds[2]; local in function:ATF_TC_BODY
88 RL(pipe(fds));
91 EV_SET(&event[0], fds[1], EVFILT_WRITE, EV_ADD|EV_ENABLE, 0, 0, 0);
97 int sz = read(fds[0], buffer, 128);
108 RL(n = write(fds[1], "foo", 3));
109 RL(close(fds[1]))
124 int fds[2]; local in function:ATF_TC_BODY
    [all...]
  /src/usr.sbin/mopd/common/
loop-linux2.c 98 fd_set fds, listeners; local in function:Loop
118 FD_ZERO(&fds);
121 FD_SET(ii->fd, &fds);
127 listeners = fds;
loop-linux2.c 98 fd_set fds, listeners; local in function:Loop
118 FD_ZERO(&fds);
121 FD_SET(ii->fd, &fds);
127 listeners = fds;
  /src/tests/lib/libc/sys/
t_pollts.c 58 int fds[2]; local in function:ATF_TC_BODY
63 ATF_REQUIRE_EQ(pipe(fds), 0);
65 pfds[0].fd = fds[0];
67 pfds[1].fd = fds[1];
104 ATF_REQUIRE_EQ(write(fds[1], "", 1), 1);
116 ATF_REQUIRE_EQ(close(fds[0]), 0);
117 ATF_REQUIRE_EQ(close(fds[1]), 0);
t_pollts.c 58 int fds[2]; local in function:ATF_TC_BODY
63 ATF_REQUIRE_EQ(pipe(fds), 0);
65 pfds[0].fd = fds[0];
67 pfds[1].fd = fds[1];
104 ATF_REQUIRE_EQ(write(fds[1], "", 1), 1);
116 ATF_REQUIRE_EQ(close(fds[0]), 0);
117 ATF_REQUIRE_EQ(close(fds[1]), 0);
t_write.c 113 int fds[2]; local in function:ATF_TC_BODY
115 ATF_REQUIRE(pipe(fds) == 0);
118 ATF_REQUIRE(write(fds[1], "x", 1) != -1);
119 ATF_REQUIRE(close(fds[0]) == 0);
124 if (write(fds[1], "x", 1) != -1 || errno != EPIPE)
127 ATF_REQUIRE(close(fds[1]) == 0);
t_write.c 113 int fds[2]; local in function:ATF_TC_BODY
115 ATF_REQUIRE(pipe(fds) == 0);
118 ATF_REQUIRE(write(fds[1], "x", 1) != -1);
119 ATF_REQUIRE(close(fds[0]) == 0);
124 if (write(fds[1], "x", 1) != -1 || errno != EPIPE)
127 ATF_REQUIRE(close(fds[1]) == 0);
  /src/tests/lib/libc/ttyio/
t_ptm.c 129 int fdm, fds; local in function:ATF_TC_BODY
152 REQUIRE_ERRNO((fds = open(pty, O_RDWR|O_NOCTTY)), -1);
153 REQUIRE_ERRNO(fstat(fds, &sts), -1);
t_ptm.c 129 int fdm, fds; local in function:ATF_TC_BODY
152 REQUIRE_ERRNO((fds = open(pty, O_RDWR|O_NOCTTY)), -1);
153 REQUIRE_ERRNO(fstat(fds, &sts), -1);
  /src/libexec/ftpd/
popen.c 103 static int fds; variable in typeref:typename:int
122 if ((fds = getdtablesize()) <= 0)
124 if ((pids = (int *)malloc((unsigned int)(fds * sizeof(int)))) == NULL)
126 memset(pids, 0, fds * sizeof(int));
popen.c 103 static int fds; variable in typeref:typename:int
122 if ((fds = getdtablesize()) <= 0)
124 if ((pids = (int *)malloc((unsigned int)(fds * sizeof(int)))) == NULL)
126 memset(pids, 0, fds * sizeof(int));
  /src/regress/sys/kern/select/
select.c 53 int fds[NPIPE][2]; variable in typeref:typename:int[][2]
67 fd = fds[i][1];
96 fd = fds[i][0];
189 if (pipe(fds[i])) {
193 if (fcntl(fds[i][0], F_SETFL, O_NONBLOCK) == -1) {

Completed in 83 milliseconds

1 2 3