]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
[media] s2255drv: index is always positive
authorMauro Carvalho Chehab <mchehab@redhat.com>
Sat, 27 Oct 2012 19:29:34 +0000 (16:29 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Sun, 28 Oct 2012 09:38:57 +0000 (07:38 -0200)
drivers/media/usb/s2255/s2255drv.c:1654:2: warning: comparison of unsigned expression < 0 is always false [-Wtype-limits]

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/usb/s2255/s2255drv.c

index 2191f6ddf9e7536883a6b7e7973ceeba30b0ef61..8ebec0d7bf59509bd19ea1756528e1e9407fbe45 100644 (file)
@@ -1651,7 +1651,7 @@ static int vidioc_enum_frameintervals(struct file *file, void *priv,
        int is_ntsc = 0;
 #define NUM_FRAME_ENUMS 4
        int frm_dec[NUM_FRAME_ENUMS] = {1, 2, 3, 5};
-       if (fe->index < 0 || fe->index >= NUM_FRAME_ENUMS)
+       if (fe->index >= NUM_FRAME_ENUMS)
                return -EINVAL;
        switch (fe->width) {
        case 640: