Lines Matching refs:dirfd
69 static int dirfd = -1; /* storage for setting created dir time/mode */ variable
1088 if (dirfd != -1) in dir_start()
1095 if ((dirfd = mkstemp(tempfile)) >= 0) { in dir_start()
1122 if (dirfd < 0) in add_dir()
1129 if ((dblk.npos = lseek(dirfd, 0L, SEEK_CUR)) < 0) { in add_dir()
1142 if ((write(dirfd, name, dblk.nlen) == dblk.nlen) && in add_dir()
1143 (write(dirfd, (char *)&dblk, sizeof(dblk)) == sizeof(dblk))) { in add_dir()
1165 if (dirfd < 0) in proc_dir()
1175 if (lseek(dirfd, -((off_t)sizeof(dblk)), SEEK_CUR) < 0) in proc_dir()
1177 if (read(dirfd,(char *)&dblk, sizeof(dblk)) != sizeof(dblk)) in proc_dir()
1179 if (lseek(dirfd, dblk.npos, SEEK_SET) < 0) in proc_dir()
1181 if (read(dirfd, name, dblk.nlen) != dblk.nlen) in proc_dir()
1183 if (lseek(dirfd, dblk.npos, SEEK_SET) < 0) in proc_dir()
1196 (void)close(dirfd); in proc_dir()
1197 dirfd = -1; in proc_dir()