mirror of
https://github.com/systemd/systemd-stable.git
synced 2024-12-22 13:33:56 +03:00
stat-util: fix fd_is_network_ns()
This was broken in 77f9fa3b8e
. My fault.
Fixes: #8543
This commit is contained in:
parent
19496554e2
commit
29f74559d4
@ -254,7 +254,8 @@ int fd_is_network_ns(int fd) {
|
||||
if (r <= 0)
|
||||
return r;
|
||||
|
||||
if (ioctl(fd, NS_GET_NSTYPE) < 0)
|
||||
r = ioctl(fd, NS_GET_NSTYPE);
|
||||
if (r < 0)
|
||||
return -errno;
|
||||
|
||||
return r == CLONE_NEWNET;
|
||||
|
Loading…
Reference in New Issue
Block a user