diff options
author | Andreas Rheinhardt <andreas.rheinhardt@gmail.com> | 2020-04-14 04:30:59 +0200 |
---|---|---|
committer | Andreas Rheinhardt <andreas.rheinhardt@gmail.com> | 2020-04-20 18:43:53 +0200 |
commit | 0fcf74f4357e949f5971d39b04a128103b8949bb (patch) | |
tree | 99c651cf5aa9ed75c0b82958dc8fcb4321ec0287 /tests/ref/vsynth/vsynth2-mpeg1 | |
parent | d026fef999f7e2491721b3878bea6e6da8b9f92e (diff) | |
download | ffmpeg-0fcf74f4357e949f5971d39b04a128103b8949bb.tar.gz |
avformat/oggenc: Don't free AVStream's priv_data, fix memleak
For FLAC, Speex, Opus and VP8 the Ogg muxer allocates two buffers
for building the headers: The first for extradata in an Ogg-specific
format and the second contains a Vorbiscomment. These buffers are
reachable via pointers in the corresponding AVStream's priv_data.
If an error happens during building the headers, the AVStream's
priv_data would be freed. This is pointless in general as it would be
freed generically anyway, but here it is actively harmful: If the second
of the aforementioned allocations fails, the first buffer would leak
upon freeing priv_data.
This commit stops freeing priv_data manually, which allows the muxer to
properly clean up in the deinit function.
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Diffstat (limited to 'tests/ref/vsynth/vsynth2-mpeg1')
0 files changed, 0 insertions, 0 deletions