mirror of
https://github.com/systemd/systemd.git
synced 2024-12-23 21:35:11 +03:00
bootctl: don't load etc/machine-info from cwd
arg_root defaults to null, so if --root isn't given, this would try reading etc/machine-info from the current working directory, which is likely to fail. Fixes:77db9ef2ab
("boot: Make sure we take --root into account everywhere.") (cherry picked from commit0452779b00
)
This commit is contained in:
parent
83f3094173
commit
8d7eef9ee5
@ -45,7 +45,7 @@ static int load_etc_machine_info(void) {
|
||||
_cleanup_free_ char *p = NULL, *s = NULL, *layout = NULL;
|
||||
int r;
|
||||
|
||||
p = path_join(arg_root, "etc/machine-info");
|
||||
p = path_join(arg_root, "/etc/machine-info");
|
||||
if (!p)
|
||||
return log_oom();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user