]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
install: rename generator_paths() → generator_binary_paths()
authorLennart Poettering <lennart@poettering.net>
Wed, 6 Apr 2016 18:48:58 +0000 (20:48 +0200)
committerLennart Poettering <lennart@poettering.net>
Tue, 12 Apr 2016 11:43:31 +0000 (13:43 +0200)
This is too confusing, as this funciton returns the paths to the generator
binaries, while usually when we refer to the just the "generator path" we mean
the generated unit files. Let's clean this up.

src/core/manager.c
src/shared/path-lookup.c
src/shared/path-lookup.h
src/test/test-path-lookup.c

index 6ce3e404c9649e66a465bdbbf7c87750c6b55366..91fe9c2d5b72bfbff360ccb1bf52851b82edc617 100644 (file)
@@ -2715,7 +2715,7 @@ static int manager_run_generators(Manager *m) {
         if (m->test_run)
                 return 0;
 
-        paths = generator_paths(m->unit_file_scope);
+        paths = generator_binary_paths(m->unit_file_scope);
         if (!paths)
                 return log_oom();
 
index 685ae895d2049104db0322baa576dcc66a1de35b..d3d4243ad4409743c04450eb630a14e1889e5a96 100644 (file)
@@ -221,7 +221,7 @@ static char** user_dirs(
         return tmp;
 }
 
-char **generator_paths(UnitFileScope scope) {
+char **generator_binary_paths(UnitFileScope scope) {
 
         switch (scope) {
 
index d151347a1b721809ca8116e3694a837687d6bbe6..29f74cf2118918b36df44464cec6c56a70e07807 100644 (file)
@@ -45,7 +45,7 @@ struct LookupPaths {
         char *root_dir;
 };
 
-char **generator_paths(UnitFileScope scope);
+char **generator_binary_paths(UnitFileScope scope);
 
 int lookup_paths_init(LookupPaths *p, UnitFileScope scope, const char *root_dir);
 
index 6ef0535ecb5dea5d2457b043d3725c6af73aeef1..ba6048286731b7bb28b3d7a91af6c7dfb122f9fb 100644 (file)
@@ -51,13 +51,13 @@ static void test_paths(UnitFileScope scope) {
         assert_se(rm_rf(template, REMOVE_ROOT|REMOVE_PHYSICAL) >= 0);
 }
 
-static void print_generator_paths(UnitFileScope scope) {
+static void print_generator_binary_paths(UnitFileScope scope) {
         _cleanup_strv_free_ char **paths;
         char **dir;
 
         log_info("Generators dirs (%s):", scope == UNIT_FILE_SYSTEM ? "system" : "user");
 
-        paths = generator_paths(scope);
+        paths = generator_binary_paths(scope);
         STRV_FOREACH(dir, paths)
                 log_info("        %s", *dir);
 }
@@ -71,8 +71,8 @@ int main(int argc, char **argv) {
         test_paths(UNIT_FILE_USER);
         test_paths(UNIT_FILE_GLOBAL);
 
-        print_generator_paths(UNIT_FILE_SYSTEM);
-        print_generator_paths(UNIT_FILE_USER);
+        print_generator_binary_paths(UNIT_FILE_SYSTEM);
+        print_generator_binary_paths(UNIT_FILE_USER);
 
         return EXIT_SUCCESS;
 }