fmt->index is unsigned. test doesn't work

Signed-off-by: Roel Kluin <roel.kl...@gmail.com>
---
Is there another test required?

diff --git a/drivers/media/video/zoran/zoran_driver.c 
b/drivers/media/video/zoran/zoran_driver.c
index 092333b..0db5d0f 100644
--- a/drivers/media/video/zoran/zoran_driver.c
+++ b/drivers/media/video/zoran/zoran_driver.c
@@ -1871,7 +1871,7 @@ static int zoran_enum_fmt(struct zoran *zr, struct 
v4l2_fmtdesc *fmt, int flag)
                if (num == fmt->index)
                        break;
        }
-       if (fmt->index < 0 /* late, but not too late */  || i == NUM_FORMATS)
+       if (i == NUM_FORMATS)
                return -EINVAL;
 
        strncpy(fmt->description, zoran_formats[i].name, 
sizeof(fmt->description)-1);

------------------------------------------------------------------------------
Crystal Reports &#45; New Free Runtime and 30 Day Trial
Check out the new simplified licensign option that enables unlimited
royalty&#45;free distribution of the report engine for externally facing 
server and web deployment.
http://p.sf.net/sfu/businessobjects
_______________________________________________
Mjpeg-users mailing list
Mjpeg-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mjpeg-users

Reply via email to