mirror of
https://github.com/systemd/systemd
synced 2024-10-14 20:17:52 +00:00
shared: fix error handling in make_inaccessible_nodes
_label wrappers return -errno on failure instead of returning -1 and
setting global errno.
Fixes: 8d9cbd809d
Follow up: #16426
This commit is contained in:
parent
b159831b61
commit
db06c162e8
|
@ -107,8 +107,8 @@ int make_inaccessible_nodes(
|
|||
else
|
||||
r = mknod_label(path, table[i].mode, makedev(0, 0));
|
||||
if (r < 0) {
|
||||
if (errno != EEXIST)
|
||||
log_debug_errno(errno, "Failed to create '%s', ignoring: %m", path);
|
||||
if (r != -EEXIST)
|
||||
log_debug_errno(r, "Failed to create '%s', ignoring: %m", path);
|
||||
continue;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue