Flush picture buffers when closing the avcodec decoder.
authorLaurent Aimar <fenrir@videolan.org>
Mon, 1 Jun 2009 09:54:50 +0000 (11:54 +0200)
committerLaurent Aimar <fenrir@videolan.org>
Mon, 1 Jun 2009 10:40:48 +0000 (12:40 +0200)
modules/codec/avcodec/video.c

index 8acbcaa..c57b0d3 100644 (file)
@@ -731,6 +731,8 @@ void EndVideoDec( decoder_t *p_dec )
 {
     decoder_sys_t *p_sys = p_dec->p_sys;
 
+    avcodec_flush_buffers( p_sys->p_context );
+
     if( p_sys->p_ff_pic ) av_free( p_sys->p_ff_pic );
     free( p_sys->p_buffer_orig );
 }