Commit 4ea8da0b authored by Dave Jones's avatar Dave Jones

[PATCH] stradis overflow check

parent 020cbcea
......@@ -1428,6 +1428,9 @@ static int saa_ioctl(struct video_device *dev, unsigned int cmd, void *arg)
if (copy_from_user(saa->dmavid2, vw.clips,
VIDEO_CLIPMAP_SIZE))
return -EFAULT;
}
else if (vw.clipcount > 16384) {
return -EINVAL;
} else if (vw.clipcount > 0) {
if ((vcp = vmalloc(sizeof(struct video_clip) *
(vw.clipcount))) == NULL)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment