mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-06 02:50:49 +09:00
media: v4l2-jpeg: ignore the unknown APP14 marker
[ Upstream commit251c0ea6ef] The legal identifier of APP14 is "Adobe\0", but sometimes it may be "This is an unknown APP marker . Compliant decoders must ignore it." In this case, just ignore it. It won't affect the decode result. Fixes:b8035f7988("media: Add parsing for APP14 data segment in jpeg helpers") Signed-off-by: Ming Qian <ming.qian@nxp.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
1cfbe44e0c
commit
3fca02c426
@@ -460,7 +460,7 @@ static int jpeg_parse_app14_data(struct jpeg_stream *stream,
|
||||
/* Check for "Adobe\0" in Ap1..6 */
|
||||
if (stream->curr + 6 > stream->end ||
|
||||
strncmp(stream->curr, "Adobe\0", 6))
|
||||
return -EINVAL;
|
||||
return jpeg_skip(stream, lp - 2);
|
||||
|
||||
/* get to Ap12 */
|
||||
ret = jpeg_skip(stream, 11);
|
||||
|
||||
Reference in New Issue
Block a user