提交 cd4d9df2 编写于 作者: A Alexandra Hájková 提交者: Anton Khirnov

asfdec: free AVDictionaries properly when closing the demuxer

Signed-off-by: NAnton Khirnov <anton@khirnov.net>
上级 90e648c5
......@@ -1453,10 +1453,12 @@ static int asf_read_close(AVFormatContext *s)
ASFContext *asf = s->priv_data;
int i;
for (i = 0; i < asf->nb_streams; i++) {
av_free_packet(&asf->asf_st[i]->pkt.avpkt);
av_freep(&asf->asf_st[i]);
for (i = 0; i < ASF_MAX_STREAMS; i++) {
av_dict_free(&asf->asf_sd[i].asf_met);
if (i < asf->nb_streams) {
av_free_packet(&asf->asf_st[i]->pkt.avpkt);
av_freep(&asf->asf_st[i]);
}
}
asf->nb_streams = 0;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册