diff --git a/builtin/add.c b/builtin/add.c index 89dce56a240d69ccb224590bf134c9656d8a0522..c689f3725e84e88765ff7a0b79fc5ad338048fce 100644 --- a/builtin/add.c +++ b/builtin/add.c @@ -453,7 +453,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"), diff --git a/builtin/ls-files.c b/builtin/ls-files.c index 31b3f2d9006e0f5703ca9fb37bea247012581c0e..ef7f99a9ed12944c2de3541e45b160967a73c869 100644 --- a/builtin/ls-files.c +++ b/builtin/ls-files.c @@ -203,7 +203,7 @@ static void show_ru_info(void) static int ce_excluded(struct path_exclude_check *check, struct cache_entry *ce) { int dtype = ce_to_dtype(ce); - return path_excluded(check, ce->name, ce_namelen(ce), &dtype); + return is_path_excluded(check, ce->name, ce_namelen(ce), &dtype); } static void show_files(struct dir_struct *dir) diff --git a/dir.c b/dir.c index f31aa59fa30f21dc2fca1b5546530d099f2bcc46..f1c0abd182e43df312c9f2ed64fcccaad9017b6a 100644 --- a/dir.c +++ b/dir.c @@ -685,8 +685,8 @@ void path_exclude_check_clear(struct path_exclude_check *check) * A path to a directory known to be excluded is left in check->path to * optimize for repeated checks for files in the same excluded directory. */ -int path_excluded(struct path_exclude_check *check, - const char *name, int namelen, int *dtype) +int is_path_excluded(struct path_exclude_check *check, + const char *name, int namelen, int *dtype) { int i; struct strbuf *path = &check->path; diff --git a/dir.h b/dir.h index 680c1eb6eaff6e01fec801f259405affdea05997..c59bad8851bed1505bdfbafecc213070f25ace32 100644 --- a/dir.h +++ b/dir.h @@ -123,7 +123,7 @@ struct path_exclude_check { }; extern void path_exclude_check_init(struct path_exclude_check *, struct dir_struct *); extern void path_exclude_check_clear(struct path_exclude_check *); -extern int path_excluded(struct path_exclude_check *, const char *, int namelen, int *dtype); +extern int is_path_excluded(struct path_exclude_check *, const char *, int namelen, int *dtype); extern int add_excludes_from_file_to_list(const char *fname, const char *base, int baselen, diff --git a/unpack-trees.c b/unpack-trees.c index 33a581924e11167dc546bdf97c8d49460b43674e..3ac6370f991db5ecbc7ed12a36d5c25040eed265 100644 --- a/unpack-trees.c +++ b/unpack-trees.c @@ -1372,7 +1372,7 @@ static int check_ok_to_remove(const char *name, int len, int dtype, return 0; if (o->dir && - path_excluded(o->path_exclude_check, name, -1, &dtype)) + is_path_excluded(o->path_exclude_check, name, -1, &dtype)) /* * ce->name is explicitly excluded, so it is Ok to * overwrite it.