mirror of https://git.ffmpeg.org/ffmpeg.git
avformat/oggdec: Fix metadata memleak on multiple headers
Fixes: Chromium bug 800123 Reported-by: Matt Wolenetz <wolenetz@google.com> Reviewed-by: Matt Wolenetz <wolenetz@google.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
parent
3934aa495d
commit
da069e9c68
|
@ -128,7 +128,10 @@ static int ogg_restore(AVFormatContext *s)
|
|||
ogg->state = ost->next;
|
||||
|
||||
for (i = 0; i < ogg->nstreams; i++) {
|
||||
av_freep(&ogg->streams[i].buf);
|
||||
struct ogg_stream *stream = &ogg->streams[i];
|
||||
av_freep(&stream->buf);
|
||||
av_freep(&stream->new_metadata);
|
||||
|
||||
if (i >= ost->nstreams || !ost->streams[i].private) {
|
||||
free_stream(s, i);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue