[FFmpeg-devel] [PATCH v2] ffprobe: Fix memory leak
    James Almer 
    jamrial at gmail.com
       
    Fri Jun 21 17:26:08 EEST 2019
    
    
  
On 6/21/2019 11:15 AM, Derek Buitenhuis wrote:
> This packet was not necessarily unreferenced.
> 
> Signed-off-by: Derek Buitenhuis <derek.buitenhuis at gmail.com>
> ---
>  fftools/ffprobe.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/fftools/ffprobe.c b/fftools/ffprobe.c
> index 3becb6330e..dac70ba5a1 100644
> --- a/fftools/ffprobe.c
> +++ b/fftools/ffprobe.c
> @@ -2429,6 +2429,8 @@ static int read_interval_packets(WriterContext *w, InputFile *ifile,
>          }
>          av_packet_unref(&pkt);
>      }
> +    av_packet_unref(&pkt);
> +
Remove the three lines below as well before pushing. They are
superfluous as av_packet_unref() does the same internally.
>      av_init_packet(&pkt);
>      pkt.data = NULL;
>      pkt.size = 0;
> 
    
    
More information about the ffmpeg-devel
mailing list