Return the status of the directory identified by FTS and ENT. This is -1 if the directory is empty, 0 if it is nonempty, and a positive error number if there was trouble determining the status, e.g., it is not a directory, or permissions problems, or I/O errors. Use *DIR_STATUS as a cache for the status. */
| 165 | e.g., it is not a directory, or permissions problems, or I/O errors. |
| 166 | Use *DIR_STATUS as a cache for the status. */ |
| 167 | static int |
| 168 | get_dir_status (FTS const *fts, FTSENT const *ent, int *dir_status) |
| 169 | { |
| 170 | if (*dir_status == DS_UNKNOWN) |
| 171 | *dir_status = directory_status (fts->fts_cwd_fd, ent->fts_accpath); |
| 172 | return *dir_status; |
| 173 | } |
| 174 | |
| 175 | /* Prompt whether to remove FILENAME, if required via a combination of |
| 176 | the options specified by X and/or file attributes. If the file may |
no test coverage detected