# HG changeset patch # User vitor # Date 1268227070 0 # Node ID ee47b525644cabee0fb1771822667868fff72ff7 # Parent 9f349253996d4cedc263f2ea6da198def61ed503 Fix memory leak in FFM demuxer diff -r 9f349253996d -r ee47b525644c ffmdec.c --- a/ffmdec.c Wed Mar 10 09:20:32 2010 +0000 +++ b/ffmdec.c Wed Mar 10 13:17:50 2010 +0000 @@ -512,6 +512,14 @@ return 0; } +static void ffm_close(AVFormatContext *s) +{ + int i; + + for (i = 0; i < s->nb_streams; i++) + av_freep(&s->streams[i]->codec->rc_eq); +} + AVInputFormat ffm_demuxer = { "ffm", NULL_IF_CONFIG_SMALL("FFM (FFserver live feed) format"), @@ -519,6 +527,6 @@ ffm_probe, ffm_read_header, ffm_read_packet, - NULL, + ffm_close, ffm_seek, };