Skip to content

Commit

Permalink
V4L/DVB (9878): gspca - vc032x: Fix frame overflow errors with vc0321.
Browse files Browse the repository at this point in the history
The vc0321 sends some additional data after sending the complete
frame, we ignore this.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
  • Loading branch information
Hans de Goede authored and Mauro Carvalho Chehab committed Dec 30, 2008
1 parent 11d9f25 commit d473a00
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions drivers/media/video/gspca/vc032x.c
Original file line number Diff line number Diff line change
Expand Up @@ -2272,6 +2272,12 @@ static void sd_pkt_scan(struct gspca_dev *gspca_dev,
data, len);
return;
}

/* The vc0321 sends some additional data after sending the complete
* frame, we ignore this. */
if (sd->bridge == BRIDGE_VC0321
&& len > frame->v4l2_buf.length - (frame->data_end - frame->data))
len = frame->v4l2_buf.length - (frame->data_end - frame->data);
gspca_frame_add(gspca_dev, INTER_PACKET, frame, data, len);
}

Expand Down

0 comments on commit d473a00

Please sign in to comment.