X-Git-Url: https://git.openpandora.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=fs%2Fcompat_ioctl.c;h=f854cf9355a8e2dc03f0670953d789f29c65e4d0;hb=e813577167c4a1c3f25cd9d84c29301b82d95597;hp=51352de88ef10ea41583661f39625f93b475aa34;hpb=e060c38434b2caa78efe7cedaff4191040b65a15;p=pandora-kernel.git diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c index 51352de88ef1..f854cf9355a8 100644 --- a/fs/compat_ioctl.c +++ b/fs/compat_ioctl.c @@ -210,6 +210,8 @@ static int do_video_set_spu_palette(unsigned int fd, unsigned int cmd, err = get_user(palp, &up->palette); err |= get_user(length, &up->length); + if (err) + return -EFAULT; up_native = compat_alloc_user_space(sizeof(struct video_spu_palette)); err = put_user(compat_ptr(palp), &up_native->palette);