Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 11edebc2 authored by Antonio Ospite's avatar Antonio Ospite Committed by Mauro Carvalho Chehab
Browse files

V4L/DVB: gspca - ov534: Fix end of frame handling



Fix a regression, introduced in the driver split, which made
the ov534 driver unusable.
Plus, the debug message should reflect that we discard also packets
beyond the expected frame size.

Signed-off-by: default avatarAntonio Ospite <ospite@studenti.unina.it>
Signed-off-by: default avatarJean-Francois Moine <moinejf@free.fr>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent 29b87f04
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -992,9 +992,9 @@ static void sd_pkt_scan(struct gspca_dev *gspca_dev,
			frame = gspca_get_i_frame(gspca_dev);
			if (frame == NULL)
				goto discard;
			if (frame->data_end - frame->data !=
			if (frame->data_end - frame->data + (len - 12) !=
			    gspca_dev->width * gspca_dev->height * 2) {
				PDEBUG(D_PACK, "short frame");
				PDEBUG(D_PACK, "wrong sized frame");
				goto discard;
			}
			gspca_frame_add(gspca_dev, LAST_PACKET,