Lines Matching refs:fd
25 int fd, ret;
27 if ((fd = mkstemp(temp)) < 0)
31 if (write(fd, zeroes, sizeof(zeroes)) != sizeof(zeroes))
34 if (lseek(fd, 5, SEEK_SET) != 5)
42 if (pwritev(fd, iov, 2, 4) != 4)
45 if (read(fd, &c, 1) != 1)
52 if (write(fd, &c, 1) != 1)
55 if (pread(fd, buf, 10, 0) != 10)
60 if ((ret = pwritev(fd, iov, 2, -1)) != -1)
66 if ((ret = pwritev(fd, iov, 2, LLONG_MAX)) != -1)
76 if (fcntl(fd, F_SETFL, fcntl(fd, F_GETFL) | O_APPEND))
78 if (pwritev(fd, iov, 2, 2) != 4)
80 if (pread(fd, buf, 10, 0) != 10)
85 close(fd);
88 fd = open("/dev/tty", O_RDWR);
89 if (fd < 0)
91 else if ((ret = pwritev(fd, iov, 2, 7)) != -1)