Commit 902e4575 authored by Mauro Carvalho Chehab's avatar Mauro Carvalho Chehab

[media] go7007-v4l2: warning fix: index is unsigned, so it will never be below 0

drivers/staging/media/go7007/go7007-v4l2.c: In function 'vidioc_qbuf':
drivers/staging/media/go7007/go7007-v4l2.c:815:2: warning: comparison of unsigned expression < 0 is always false [-Wtype-limits]
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent 067d8513
...@@ -812,7 +812,7 @@ static int vidioc_qbuf(struct file *file, void *priv, struct v4l2_buffer *buf) ...@@ -812,7 +812,7 @@ static int vidioc_qbuf(struct file *file, void *priv, struct v4l2_buffer *buf)
return retval; return retval;
mutex_lock(&gofh->lock); mutex_lock(&gofh->lock);
if (buf->index < 0 || buf->index >= gofh->buf_count) if (buf->index >= gofh->buf_count)
goto unlock_and_return; goto unlock_and_return;
gobuf = &gofh->bufs[buf->index]; gobuf = &gofh->bufs[buf->index];
......
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