Lines Matching refs:sb
61 struct stat sb; in command_ls() local
93 if (stat(path, &sb) == 0 && !S_ISDIR(sb.st_mode)) { in command_ls()
96 typestr[sb.st_mode >> 12], in command_ls()
97 (int)sb.st_size, path); in command_ls()
100 typestr[sb.st_mode >> 12], path); in command_ls()
118 sb.st_size = 0; in command_ls()
119 sb.st_mode = 0; in command_ls()
124 if (stat(buf, &sb)) { in command_ls()
125 sb.st_size = 0; in command_ls()
126 sb.st_mode = 0; in command_ls()
133 typestr[d->d_type? d->d_type:sb.st_mode >> 12], in command_ls()
134 (int)sb.st_size, d->d_name); in command_ls()
137 typestr[d->d_type? d->d_type:sb.st_mode >> 12], d->d_name); in command_ls()
158 struct stat sb; in ls_getdir() local
192 if (fstat(fd, &sb) < 0) { in ls_getdir()
197 if (!S_ISDIR(sb.st_mode)) { in ls_getdir()