Skip to content

Commit 19988c5

Browse files
Qiu Qiangslouken
authored andcommitted
Fix loop variable bug in V4L2 camera format enumeration
1 parent 7773157 commit 19988c5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/camera/v4l2/SDL_camera_v4l2.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -801,7 +801,7 @@ static void MaybeAddDevice(const char *path)
801801
const int stepw = (int) frmsizeenum.stepwise.step_width;
802802
const int steph = (int) frmsizeenum.stepwise.step_height;
803803
for (int w = minw; w <= maxw; w += stepw) {
804-
for (int h = minh; w <= maxh; w += steph) {
804+
for (int h = minh; h <= maxh; h += steph) {
805805
#if DEBUG_CAMERA
806806
SDL_Log("CAMERA: * Has %s size %dx%d", (frmsizeenum.type == V4L2_FRMSIZE_TYPE_STEPWISE) ? "stepwise" : "continuous", w, h);
807807
#endif

0 commit comments

Comments
 (0)