aboutsummaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
Diffstat (limited to 'kernel')
-rw-r--r--kernel/nsproxy.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/kernel/nsproxy.c b/kernel/nsproxy.c
index 87c37221cb7f..49746c81ad8d 100644
--- a/kernel/nsproxy.c
+++ b/kernel/nsproxy.c
@@ -222,7 +222,6 @@ SYSCALL_DEFINE2(setns, int, fd, int, nstype)
222{ 222{
223 struct task_struct *tsk = current; 223 struct task_struct *tsk = current;
224 struct nsproxy *new_nsproxy; 224 struct nsproxy *new_nsproxy;
225 struct proc_ns *ei;
226 struct file *file; 225 struct file *file;
227 struct ns_common *ns; 226 struct ns_common *ns;
228 int err; 227 int err;
@@ -232,8 +231,7 @@ SYSCALL_DEFINE2(setns, int, fd, int, nstype)
232 return PTR_ERR(file); 231 return PTR_ERR(file);
233 232
234 err = -EINVAL; 233 err = -EINVAL;
235 ei = get_proc_ns(file_inode(file)); 234 ns = get_proc_ns(file_inode(file));
236 ns = ei->ns;
237 if (nstype && (ns->ops->type != nstype)) 235 if (nstype && (ns->ops->type != nstype))
238 goto out; 236 goto out;
239 237