patch-2.4.6 linux/drivers/media/video/zr36120.c

Next file: linux/drivers/mtd/Config.in
Previous file: linux/drivers/media/video/videodev.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.4.5/linux/drivers/media/video/zr36120.c linux/drivers/media/video/zr36120.c
@@ -1025,7 +1025,7 @@
 		v.norm=VIDEO_MODE_PAL;
 #endif
 		/* too many inputs? no decoder -> no channels */
-		if (!ztv->have_decoder || v.channel >= ztv->card->video_inputs)
+		if (!ztv->have_decoder || v.channel < 0 ||  v.channel >= ztv->card->video_inputs)
 			return -EINVAL;
 
 		/* now determine the name of the channel */

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)