Merge branch 'as/dir-c-cleanup'
Refactor and generally clean up the directory traversal API implementation. * as/dir-c-cleanup: dir.c: rename free_excludes() to clear_exclude_list() dir.c: refactor is_path_excluded() dir.c: refactor is_excluded() dir.c: refactor is_excluded_from_list() dir.c: rename excluded() to is_excluded() dir.c: rename excluded_from_list() to is_excluded_from_list() dir.c: rename path_excluded() to is_path_excluded() dir.c: rename cryptic 'which' variable to more consistent name Improve documentation and comments regarding directory traversal API api-directory-listing.txt: update to match code
This commit is contained in:
@ -454,7 +454,7 @@ int cmd_add(int argc, const char **argv, const char *prefix)
|
||||
&& !file_exists(pathspec[i])) {
|
||||
if (ignore_missing) {
|
||||
int dtype = DT_UNKNOWN;
|
||||
if (path_excluded(&check, pathspec[i], -1, &dtype))
|
||||
if (is_path_excluded(&check, pathspec[i], -1, &dtype))
|
||||
dir_add_ignored(&dir, pathspec[i], strlen(pathspec[i]));
|
||||
} else
|
||||
die(_("pathspec '%s' did not match any files"),
|
||||
|
Reference in New Issue
Block a user