diff options
author | Steven Siloti <ssiloti@bittorrent.com> | 2017-07-18 11:26:39 -0700 |
---|---|---|
committer | Michael Niedermayer <michael@niedermayer.cc> | 2017-08-23 13:15:18 +0200 |
commit | 298c3bd2f419f16d0990efcf62669c73b85fb0d5 (patch) | |
tree | 8e68ce7fbff3121e99b33d0a935fab264c6fd8a7 | |
parent | 0b02123cc8bb783e7677e6de2f3f2f389f59ca6f (diff) | |
download | ffmpeg-298c3bd2f419f16d0990efcf62669c73b85fb0d5.tar.gz |
avformat/utils: fix memory leak in avformat_free_context
The pointer to the packet queue is stored in the internal structure
so the queue needs to be flushed before internal is freed.
Signed-off-by: Steven Siloti <ssiloti@bittorrent.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
(cherry picked from commit 949debd1d1df3a96315b3a3083831162845c1188)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
-rw-r--r-- | libavformat/utils.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/utils.c b/libavformat/utils.c index c713d62804..f6d82d2927 100644 --- a/libavformat/utils.c +++ b/libavformat/utils.c @@ -3554,8 +3554,8 @@ void avformat_free_context(AVFormatContext *s) av_freep(&s->chapters); av_dict_free(&s->metadata); av_freep(&s->streams); - av_freep(&s->internal); flush_packet_queue(s); + av_freep(&s->internal); av_free(s); } |