From: Sascha Hauer Date: Wed, 13 Sep 2006 16:26:11 +0000 (-0300) Subject: V4L/DVB (4628): Fix VIDIOC_ENUMSTD ioctl in videodev.c X-Git-Tag: firefly_0821_release~33017^2~10 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=666c73d9e123b9ea230fcb1e2bf47fe0294332a8;p=firefly-linux-kernel-4.4.55.git V4L/DVB (4628): Fix VIDIOC_ENUMSTD ioctl in videodev.c Do not return -EINVAL for index=0 in VIDIOC_ENUMSTD, because it is a valid index Signed-off-by: Sascha Hauer Signed-off-by: Mauro Carvalho Chehab --- diff --git a/drivers/media/video/videodev.c b/drivers/media/video/videodev.c index 2299e294e8df..26e7ea252a0e 100644 --- a/drivers/media/video/videodev.c +++ b/drivers/media/video/videodev.c @@ -836,7 +836,7 @@ static int __video_do_ioctl(struct inode *inode, struct file *file, break; } - if (index < 0 || index >= vfd->tvnormsize) { + if (index<0 || index >= vfd->tvnormsize) { ret=-EINVAL; break; }