[chore]: Bump github.com/abema/go-mp4 from 1.1.1 to 1.2.0 (#2559)

This commit is contained in:
dependabot[bot] 2024-01-22 09:42:41 +00:00 committed by GitHub
commit 605b2fde91
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
9 changed files with 170 additions and 5 deletions

View file

@ -64,6 +64,18 @@ func readBoxStructureFromInternal(r io.ReadSeeker, bi *BoxInfo, path BoxPath, ha
}
}
// parse numbered ilst items after keys box by saving EntryCount field to context
if bi.Type == BoxTypeKeys() {
var keys Keys
if _, err := Unmarshal(r, bi.Size-bi.HeaderSize, &keys, bi.Context); err != nil {
return nil, err
}
bi.QuickTimeKeysMetaEntryCount = int(keys.EntryCount)
if _, err := bi.SeekToPayload(r); err != nil {
return nil, err
}
}
ctx := bi.Context
if bi.Type == BoxTypeWave() {
ctx.UnderWave = true
@ -172,6 +184,11 @@ func readBoxStructure(r io.ReadSeeker, totalSize uint64, isRoot bool, path BoxPa
if bi.IsQuickTimeCompatible {
ctx.IsQuickTimeCompatible = true
}
// preserve keys entry count on context for subsequent ilst number item box
if bi.Type == BoxTypeKeys() {
ctx.QuickTimeKeysMetaEntryCount = bi.QuickTimeKeysMetaEntryCount
}
}
if totalSize != 0 && !ctx.IsQuickTimeCompatible {