summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'sys-kernel/xfs-sources/files/xfs-sources.CAN-2004-0075.patch')
-rw-r--r--sys-kernel/xfs-sources/files/xfs-sources.CAN-2004-0075.patch25
1 files changed, 25 insertions, 0 deletions
diff --git a/sys-kernel/xfs-sources/files/xfs-sources.CAN-2004-0075.patch b/sys-kernel/xfs-sources/files/xfs-sources.CAN-2004-0075.patch
new file mode 100644
index 000000000000..5c397deb9c46
--- /dev/null
+++ b/sys-kernel/xfs-sources/files/xfs-sources.CAN-2004-0075.patch
@@ -0,0 +1,25 @@
+--- linux-2.4.23/drivers/usb/vicam.c 2004-01-26 16:56:32.000000000 +0000
++++ linux-2.4.25/drivers/usb/vicam.c 2004-04-20 18:15:53.000000000 +0100
+@@ -601,12 +601,19 @@
+ case VIDIOCSWIN:
+ {
+
+- struct video_window *vw = (struct video_window *) arg;
+- DBG("VIDIOCSWIN %d x %d\n", vw->width, vw->height);
++ struct video_window vw;
+
+- if ( vw->width != 320 || vw->height != 240 )
++ if (copy_from_user(&vw, arg, sizeof(vw)))
++ {
+ retval = -EFAULT;
++ break;
++ }
++
++ DBG("VIDIOCSWIN %d x %d\n", vw->width, vw->height);
+
++ if ( vw.width != 320 || vw.height != 240 )
++ retval = -EFAULT;
++
+ break;
+ }
+