mirror of
https://github.com/systemd/systemd-stable.git
synced 2025-01-12 09:17:44 +03:00
sysupdate: fix error handling
This commit is contained in:
parent
60f53dd5cc
commit
7a692931ab
@ -557,7 +557,7 @@ int resource_resolve_path(
|
||||
return log_error_errno(r, "Failed to resolve '%s': %m", rr->path);
|
||||
|
||||
if (fstat(fd, &st) < 0)
|
||||
return log_error_errno(r, "Failed to stat '%s': %m", resolved);
|
||||
return log_error_errno(errno, "Failed to stat '%s': %m", resolved);
|
||||
|
||||
if (S_ISBLK(st.st_mode) && root)
|
||||
return log_error_errno(SYNTHETIC_ERRNO(EPERM), "When using --root= or --image= access to device nodes is prohibited.");
|
||||
|
Loading…
Reference in New Issue
Block a user