gentoo: use /var/run for new /run compatibility
[util-vserver.git] / lib / syscall_setnamespace-v13.hc
index ce7d5ad..dd1bf88 100644 (file)
 #include "vserver.h"
 
 static inline ALWAYSINLINE int
-vc_set_namespace_v13(int UNUSED tmp)
+vc_set_namespace_v13(xid_t xid, uint_least64_t mask, uint32_t index)
 {
-  return vserver(VCMD_set_namespace, -1, 0);
+  if ((mask & (CLONE_NEWNS|CLONE_FS)) == 0)
+    return 0;
+  if (index != 0) {
+    errno = EINVAL;
+    return -1;
+  }
+  return vserver(VCMD_set_space_v0, CTX_USER2KERNEL(xid), 0);
 }