Home | History | Annotate | Download | only in sys

Lines Matching defs:fd2

58 	int fd, fd1, fd2;
70 fd2 = open("/etc/passwd", O_RDONLY);
73 ATF_REQUIRE(fd2 >= 0);
78 fd = dup2(fd1, fd2);
80 fd = dup3(fd1, fd2, O_CLOEXEC);
98 (void)close(fd2);
112 int fd, fd1, fd2;
115 fd2 = open("/etc/passwd", O_RDONLY);
118 ATF_REQUIRE(fd2 >= 0);
120 fd = dup2(fd1, fd2);
123 if (fd != fd2)
129 ATF_REQUIRE(close(fd2) != 0);