| 589 | } |
| 590 | |
| 591 | static bool has_filesystem_root(const char *path) { |
| 592 | static const char *const roots[] = {"etc", "root", "var", "usr", "home", "tmp", |
| 593 | "private", "opt", "bin", "sbin", "dev", "proc", |
| 594 | "sys", "run", "lib", "lib64", "mnt", "media", |
| 595 | "boot", "srv", "Users", "Volumes", NULL}; |
| 596 | for (int i = 0; roots[i]; i++) { |
| 597 | if (starts_with_segment(path, roots[i])) { |
| 598 | return true; |
| 599 | } |
| 600 | } |
| 601 | return false; |
| 602 | } |
| 603 | |
| 604 | static bool has_hidden_config_segment(const char *path) { |
| 605 | static const char *const segments[] = {".aws", ".azure", ".config", ".docker", ".env", |
no test coverage detected