path-util: simplify final path for find_executable()

Currently, systemd-run ./test.sh would set Description=
to $PWD/./test.sh. This is quite ugly.
This commit is contained in:
Mike Yuan
2024-07-23 18:48:15 +02:00
parent 51b271ead7
commit 0e7eda91f4
+2
View File
@@ -669,6 +669,8 @@ static int find_executable_impl(const char *name, const char *root, char **ret_f
r = path_make_absolute_cwd(name, ret_filename);
if (r < 0)
return r;
path_simplify(*ret_filename);
}
if (ret_fd)