Commit 76b08116 authored by Roel Kluin's avatar Roel Kluin Committed by Mauro Carvalho Chehab

V4L/DVB (11961): tvp514x: try_count off by one

With `while (try_count-- > 0)' try_count reaches -1 after the loop.
Signed-off-by: default avatarRoel Kluin <roel.kluin@gmail.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarDouglas Schilling Landgraf <dougsland@redhat.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent bcd3e4b3
...@@ -692,7 +692,7 @@ static int ioctl_s_routing(struct v4l2_int_device *s, ...@@ -692,7 +692,7 @@ static int ioctl_s_routing(struct v4l2_int_device *s,
break; /* Input detected */ break; /* Input detected */
} }
if ((current_std == STD_INVALID) || (try_count <= 0)) if ((current_std == STD_INVALID) || (try_count < 0))
return -EINVAL; return -EINVAL;
decoder->current_std = current_std; decoder->current_std = current_std;
......
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