Support __NR_set_ns as well.

Apparently some older systems didn't have __NR_setns but had __NR_set_ns. Signed-off-by: 's avatarStéphane Graber <stgraber@ubuntu.com>
parent e43157b4
......@@ -56,6 +56,8 @@ static inline int setns(int fd, int nstype)
{
#ifdef __NR_setns
return syscall(__NR_setns, fd, nstype);
#elif __NR_set_ns
return syscall(__NR_set_ns, fd, nstype);
#else
errno = ENOSYS;
return -1;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment