diff options
author | Jinjie Ruan <[email protected]> | 2024-10-28 16:02:56 +0800 |
---|---|---|
committer | Hans Verkuil <[email protected]> | 2024-11-07 09:05:57 +0100 |
commit | d2842dec577900031826dc44e9bf0c66416d7173 (patch) | |
tree | 801a84d353f8e286131b18d361374104a86c662e /tools/perf/scripts/python/netdev-times.py | |
parent | 2a20869f7d798aa2b69e45b863eaf1b1ecf98278 (diff) |
media: gspca: ov534-ov772x: Fix off-by-one error in set_frame_rate()
In set_frame_rate(), select a rate in rate_0 or rate_1 by checking
sd->frame_rate >= r->fps in a loop, but the loop condition terminates when
the index reaches zero, which fails to check the last elememt in rate_0 or
rate_1.
Check for >= 0 so that the last one in rate_0 or rate_1 is also checked.
Fixes: 189d92af707e ("V4L/DVB (13422): gspca - ov534: ov772x changes from Richard Kaswy.")
Cc: [email protected]
Signed-off-by: Jinjie Ruan <[email protected]>
Signed-off-by: Sakari Ailus <[email protected]>
Signed-off-by: Hans Verkuil <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/netdev-times.py')
0 files changed, 0 insertions, 0 deletions