Lines Matching refs:stat

47     struct stat st;
49 } stat;
76 struct stat *stat = (struct stat *)&TT.stat; in print_stat() local
78 if (type == 'a') out('o', stat->st_mode&~S_IFMT); in print_stat()
82 mode_to_string(stat->st_mode, str); in print_stat()
84 } else if (type == 'b') out('u', stat->st_blocks); in print_stat()
91 } else if (type == 'd') out('d', stat->st_dev); in print_stat()
92 else if (type == 'D') out('x', stat->st_dev); in print_stat()
93 else if (type == 'f') out('x', stat->st_mode); in print_stat()
97 int i, filetype = stat->st_mode & S_IFMT; in print_stat()
100 if (!stat->st_size && filetype == S_IFREG) t = "regular empty file"; in print_stat()
102 } else if (type == 'g') out('u', stat->st_gid); in print_stat()
103 else if (type == 'G') strout(getgroupname(stat->st_gid)); in print_stat()
104 else if (type == 'h') out('u', stat->st_nlink); in print_stat()
105 else if (type == 'i') out('u', stat->st_ino); in print_stat()
108 dev_t dev = stat->st_rdev ? stat->st_rdev : stat->st_dev; in print_stat()
111 for (dlist_terminate(mt); mt; mt = mt->next) if (mt->stat.st_dev == dev) { in print_stat()
118 if (S_ISLNK(stat->st_mode)) in print_stat()
121 } else if (type == 'o') out('u', stat->st_blksize); in print_stat()
122 else if (type == 's') out('u', stat->st_size); in print_stat()
123 else if (type == 't') out('x', dev_major(stat->st_rdev)); in print_stat()
124 else if (type == 'T') out('x', dev_minor(stat->st_rdev)); in print_stat()
125 else if (type == 'u') out('u', stat->st_uid); in print_stat()
126 else if (type == 'U') strout(getusername(stat->st_uid)); in print_stat()
127 else if (type == 'x') date_stat_format(&stat->st_atim); in print_stat()
128 else if (type == 'X') out('u', stat->st_atime); in print_stat()
129 else if (type == 'y') date_stat_format(&stat->st_mtim); in print_stat()
130 else if (type == 'Y') out('u', stat->st_mtime); in print_stat()
131 else if (type == 'z') date_stat_format(&stat->st_ctim); in print_stat()
132 else if (type == 'Z') out('u', stat->st_ctime); in print_stat()
137 struct statfs *statfs = (struct statfs *)&TT.stat; in print_statfs()
183 if (flagf && !statfs(TT.file, (void *)&TT.stat)); in stat_main()
184 else if (flagf || (FLAG(L) ? stat : lstat)(TT.file, (void *)&TT.stat)) { in stat_main()