diff options
Diffstat (limited to 'fs/compat.c')
-rw-r--r-- | fs/compat.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/compat.c b/fs/compat.c index 3f3e8f4d43d6..01f39f87f372 100644 --- a/fs/compat.c +++ b/fs/compat.c | |||
@@ -1323,7 +1323,7 @@ compat_sys_vmsplice(int fd, const struct compat_iovec __user *iov32, | |||
1323 | { | 1323 | { |
1324 | unsigned i; | 1324 | unsigned i; |
1325 | struct iovec *iov; | 1325 | struct iovec *iov; |
1326 | if (nr_segs >= UIO_MAXIOV) | 1326 | if (nr_segs > UIO_MAXIOV) |
1327 | return -EINVAL; | 1327 | return -EINVAL; |
1328 | iov = compat_alloc_user_space(nr_segs * sizeof(struct iovec)); | 1328 | iov = compat_alloc_user_space(nr_segs * sizeof(struct iovec)); |
1329 | for (i = 0; i < nr_segs; i++) { | 1329 | for (i = 0; i < nr_segs; i++) { |
@@ -1913,7 +1913,7 @@ asmlinkage long compat_sys_ppoll(struct pollfd __user *ufds, | |||
1913 | } | 1913 | } |
1914 | 1914 | ||
1915 | if (sigmask) { | 1915 | if (sigmask) { |
1916 | if (sigsetsize |= sizeof(compat_sigset_t)) | 1916 | if (sigsetsize != sizeof(compat_sigset_t)) |
1917 | return -EINVAL; | 1917 | return -EINVAL; |
1918 | if (copy_from_user(&ss32, sigmask, sizeof(ss32))) | 1918 | if (copy_from_user(&ss32, sigmask, sizeof(ss32))) |
1919 | return -EFAULT; | 1919 | return -EFAULT; |