X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=src%2Fshared%2Finstall.c;h=37191a7c71ae3d181096829f384179fe137ede14;hb=0193ad26ba121f3df259cc8b3bab54a99b8e5252;hp=5bb33859832e4518a07027a12cd4d06915c07ed9;hpb=56e73b34ce0b020ef54c0dc2aba16e50d4fea9f5;p=elogind.git diff --git a/src/shared/install.c b/src/shared/install.c index 5bb338598..37191a7c7 100644 --- a/src/shared/install.c +++ b/src/shared/install.c @@ -58,22 +58,6 @@ static int in_search_path(const char *path, char **search) { return strv_contains(search, parent); } -static int lookup_paths_init_from_scope(LookupPaths *paths, - UnitFileScope scope, - const char *root_dir) { - assert(paths); - assert(scope >= 0); - assert(scope < _UNIT_FILE_SCOPE_MAX); - - zero(*paths); - - return lookup_paths_init(paths, - scope == UNIT_FILE_SYSTEM ? SYSTEMD_SYSTEM : SYSTEMD_USER, - scope == UNIT_FILE_USER, - root_dir, - NULL, NULL, NULL); -} - static int get_config_path(UnitFileScope scope, bool runtime, const char *root_dir, char **ret) { char *p = NULL; int r; @@ -240,7 +224,7 @@ static int remove_marked_symlinks_fd( if (!de) break; - if (ignore_file(de->d_name)) + if (hidden_file(de->d_name)) continue; dirent_ensure_type(d, de); @@ -415,7 +399,7 @@ static int find_symlinks_fd( if (!de) return r; - if (ignore_file(de->d_name)) + if (hidden_file(de->d_name)) continue; dirent_ensure_type(d, de); @@ -538,7 +522,6 @@ static int find_symlinks_in_scope( assert(scope < _UNIT_FILE_SCOPE_MAX); assert(name); - /* First look in runtime config path */ r = get_config_path(scope, true, root_dir, &path); if (r < 0) @@ -2095,7 +2078,7 @@ int unit_file_preset_all( if (!de) break; - if (ignore_file(de->d_name)) + if (hidden_file(de->d_name)) continue; if (!unit_name_is_valid(de->d_name, TEMPLATE_VALID)) @@ -2207,7 +2190,7 @@ int unit_file_get_list( if (!de) break; - if (ignore_file(de->d_name)) + if (hidden_file(de->d_name)) continue; if (!unit_name_is_valid(de->d_name, TEMPLATE_VALID))