Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Also check the type "skip" for a FreeSpaceBox #2407

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion src/read.c
Original file line number Diff line number Diff line change
Expand Up @@ -4153,7 +4153,8 @@ static avifResult avifParse(avifDecoder * decoder)
}
#endif

if (!isFtyp && (isNonSkippableVariableLengthBox || !memcmp(header.type, "free", 4) || !memcmp(header.type, "mdat", 4))) {
if (!isFtyp && (isNonSkippableVariableLengthBox || !memcmp(header.type, "free", 4) || !memcmp(header.type, "skip", 4) ||
!memcmp(header.type, "mdat", 4))) {
// Section 6.3.4 of ISO/IEC 14496-12:
// The FileTypeBox shall occur before any variable-length box (e.g. movie, free space, media data).
AVIF_CHECKERR(ftypSeen, AVIF_RESULT_BMFF_PARSE_FAILED);
Expand Down
Loading