Returns true if and only if "dir" is a leading directory of "path" */
| 49 | |
| 50 | /* Returns true if and only if "dir" is a leading directory of "path" */ |
| 51 | static int is_dir_prefix(const char *path, const char *dir, int dirlen) |
| 52 | { |
| 53 | return !strncmp(path, dir, dirlen) && |
| 54 | (!path[dirlen] || path[dirlen] == '/'); |
| 55 | } |
| 56 | |
| 57 | static int check_recursion_depth(const struct strbuf *name, |
| 58 | const struct pathspec *ps, |
no outgoing calls
no test coverage detected