| 224 | } |
| 225 | |
| 226 | int hb_is_valid_batch_path(const char *filename) |
| 227 | { |
| 228 | hb_stat_t sb; |
| 229 | |
| 230 | if (hb_stat(filename, &sb)) |
| 231 | { |
| 232 | return 0; |
| 233 | } |
| 234 | |
| 235 | if (S_ISDIR(sb.st_mode)) |
| 236 | { |
| 237 | return 0; |
| 238 | } |
| 239 | |
| 240 | if (!S_ISREG(sb.st_mode)) |
| 241 | { |
| 242 | return 0; |
| 243 | } |
| 244 | |
| 245 | return 1; |
| 246 | } |
| 247 | |
| 248 | /*********************************************************************** |
| 249 | * hb_batch_close |
no test coverage detected