Commit 0a813311 authored by Michael Niedermayer's avatar Michael Niedermayer

avformat/mov: Fix extradata memleak

Fixes: crbug 822705
Reported-by: 's avatarMatt Wolenetz <wolenetz@google.com>
Reviewed-by: 's avatarMatt Wolenetz <wolenetz@google.com>
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent a06175d7
......@@ -2592,6 +2592,12 @@ static int mov_read_stsd(MOVContext *c, AVIOContext *pb, MOVAtom atom)
return mov_finalize_stsd_codec(c, pb, st, sc);
fail:
if (sc->extradata) {
int j;
for (j = 0; j < sc->stsd_count; j++)
av_freep(&sc->extradata[j]);
}
av_freep(&sc->extradata);
av_freep(&sc->extradata_size);
return ret;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment