aboutsummaryrefslogtreecommitdiffstats
path: root/fs/compat.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/compat.c')
-rw-r--r--fs/compat.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/fs/compat.c b/fs/compat.c
index 2a88477330fc..263990ae4096 100644
--- a/fs/compat.c
+++ b/fs/compat.c
@@ -2170,9 +2170,12 @@ asmlinkage long compat_sys_nfsservctl(int cmd, struct compat_nfsctl_arg __user *
2170 2170
2171 default: 2171 default:
2172 err = -EINVAL; 2172 err = -EINVAL;
2173 goto done; 2173 break;
2174 } 2174 }
2175 2175
2176 if (err)
2177 goto done;
2178
2176 oldfs = get_fs(); 2179 oldfs = get_fs();
2177 set_fs(KERNEL_DS); 2180 set_fs(KERNEL_DS);
2178 /* The __user pointer casts are valid because of the set_fs() */ 2181 /* The __user pointer casts are valid because of the set_fs() */