avformat/mpegenc: Fix leak in case trailer is never written
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
This commit is contained in:
parent
cfce16449c
commit
54987a37da
1 changed files with 5 additions and 0 deletions
|
|
@ -1262,6 +1262,11 @@ static void mpeg_mux_deinit(AVFormatContext *ctx)
|
|||
StreamInfo *stream = ctx->streams[i]->priv_data;
|
||||
if (!stream)
|
||||
continue;
|
||||
for (PacketDesc *pkt = stream->predecode_packet; pkt; ) {
|
||||
PacketDesc *tmp = pkt->next;
|
||||
av_free(pkt);
|
||||
pkt = tmp;
|
||||
}
|
||||
av_fifo_freep(&stream->fifo);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue