Skip to content

Commit

Permalink
V4L/DVB (4584): Fix VIDIOC_S_FMT min/max check in pvrusb2
Browse files Browse the repository at this point in the history
Acked-by: Mike Isely <isely@pobox.com>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
  • Loading branch information
Hans Verkuil authored and Mauro Carvalho Chehab committed Sep 26, 2006
1 parent f2a49bc commit b31e341
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions drivers/media/video/pvrusb2/pvrusb2-v4l2.c
Original file line number Diff line number Diff line change
Expand Up @@ -468,18 +468,18 @@ static int pvr2_v4l2_do_ioctl(struct inode *inode, struct file *file,

lmin = pvr2_ctrl_get_min(hcp);
lmax = pvr2_ctrl_get_max(hcp);
if (h < lmin) {
h = lmin;
} else if (h > lmax) {
h = lmax;
}
lmin = pvr2_ctrl_get_min(vcp);
lmax = pvr2_ctrl_get_max(vcp);
if (w < lmin) {
w = lmin;
} else if (w > lmax) {
w = lmax;
}
lmin = pvr2_ctrl_get_min(vcp);
lmax = pvr2_ctrl_get_max(vcp);
if (h < lmin) {
h = lmin;
} else if (h > lmax) {
h = lmax;
}

memcpy(vf, &pvr_format[PVR_FORMAT_PIX],
sizeof(struct v4l2_format));
Expand Down

0 comments on commit b31e341

Please sign in to comment.