avformat/mov: don't read key_size bytes twice in the keys atom
We only support mdta as type, yet we were not skipping other types, but rather reading key_size worth of bytes twice per entry. Signed-off-by: James Almer <jamrial@gmail.com> (cherry picked from commit 5a06d3810e41134ee9c2941cc0b371da62b539db)
This commit is contained in:
parent
0085da21b4
commit
fb8f0ea7b3
@ -5048,6 +5048,7 @@ static int mov_read_keys(MOVContext *c, AVIOContext *pb, MOVAtom atom)
|
|||||||
key_size -= 8;
|
key_size -= 8;
|
||||||
if (type != MKTAG('m','d','t','a')) {
|
if (type != MKTAG('m','d','t','a')) {
|
||||||
avio_skip(pb, key_size);
|
avio_skip(pb, key_size);
|
||||||
|
continue;
|
||||||
}
|
}
|
||||||
c->meta_keys[i] = av_mallocz(key_size + 1);
|
c->meta_keys[i] = av_mallocz(key_size + 1);
|
||||||
if (!c->meta_keys[i])
|
if (!c->meta_keys[i])
|
||||||
|
Loading…
x
Reference in New Issue
Block a user