chase: replace path_prefix_root_cwd() with chaseat_prefix_root()
The function path_prefix_root_cwd() was introduced for prefixing the result from chaseat() with root, but - it is named slightly generic, - the logic is different from what chase() does. This makes the name more explanative and specific for the result of the chaseat(), and make the logic consistent with chase(). Fixes https://github.com/systemd/systemd/pull/27199#issuecomment-1511387731. Follow-up for #27199.
This commit is contained in:
+2
-2
@@ -155,7 +155,7 @@ int open_os_release(const char *root, char **ret_path, int *ret_fd) {
|
||||
return r;
|
||||
|
||||
if (ret_path) {
|
||||
r = path_prefix_root_cwd(p, root, ret_path);
|
||||
r = chaseat_prefix_root(p, root, ret_path);
|
||||
if (r < 0)
|
||||
return r;
|
||||
}
|
||||
@@ -292,7 +292,7 @@ int open_extension_release(
|
||||
return r;
|
||||
|
||||
if (ret_path) {
|
||||
r = path_prefix_root_cwd(p, root, ret_path);
|
||||
r = chaseat_prefix_root(p, root, ret_path);
|
||||
if (r < 0)
|
||||
return r;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user