vformat/utils: call flush_packet_queue() from avformat_free_context()
authorMichael Niedermayer <michaelni@gmx.at>
Fri, 15 Aug 2014 17:48:28 +0000 (19:48 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Fri, 15 Aug 2014 17:48:28 +0000 (19:48 +0200)
This avoids some theoretical memleaks

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavformat/utils.c

index 34eca17..b4ca342 100644 (file)
@@ -3525,7 +3525,7 @@ void avformat_free_context(AVFormatContext *s)
     av_dict_free(&s->metadata);
     av_freep(&s->streams);
     av_freep(&s->internal);
-    free_packet_buffer(&s->packet_buffer, &s->packet_buffer_end);
+    flush_packet_queue(s);
     av_free(s);
 }