From: Zbigniew Jędrzejewski-Szmek Date: Thu, 14 Sep 2023 10:45:43 +0000 (+0200) Subject: path: rename functions X-Git-Tag: v255-rc1~528^2~2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=c19c5aa5b33c72d051e4920994aa8fc257eac3ba;p=thirdparty%2Fsystemd.git path: rename functions When this was originally added in 9a00f57a5ba7ed431e6bac8d8b36518708503b4e, the lookup function was called sd_path_home. But it was generalized a long time ago. --- diff --git a/src/path/path.c b/src/path/path.c index 4f9ab61fbdd..a02047d1107 100644 --- a/src/path/path.c +++ b/src/path/path.c @@ -101,7 +101,7 @@ static const char* const path_table[_SD_PATH_MAX] = { [SD_PATH_SYSTEMD_SEARCH_USER_ENVIRONMENT_GENERATOR] = "systemd-search-user-environment-generator", }; -static int list_homes(void) { +static int list_paths(void) { int r = 0; for (size_t i = 0; i < ELEMENTSOF(path_table); i++) { @@ -123,7 +123,7 @@ static int list_homes(void) { return r; } -static int print_home(const char *n) { +static int print_path(const char *n) { int r; for (size_t i = 0; i < ELEMENTSOF(path_table); i++) @@ -217,9 +217,9 @@ static int run(int argc, char* argv[]) { if (argc > optind) for (int i = optind; i < argc; i++) - RET_GATHER(r, print_home(argv[i])); + RET_GATHER(r, print_path(argv[i])); else - r = list_homes(); + r = list_paths(); return r; }