[FFmpeg-devel] [PATCH] ffmpeg: free last sub when using -fix_sub_duration.

Nicolas George nicolas.george at normalesup.org
Sun Feb 24 12:15:37 CET 2013


L'octidi 18 pluviôse, an CCXXI, Nicolas George a écrit :
> Fix trac ticket #2242.
> 
> Note: under valid circumstances, when using -fix_sub_duration,
> the last subtitle is a dummy termination packet, with no
> allocated memory.
> 
> Signed-off-by: Nicolas George <nicolas.george at normalesup.org>
> ---
>  ffmpeg.c |    1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/ffmpeg.c b/ffmpeg.c
> index bda7610..569a0bc 100644
> --- a/ffmpeg.c
> +++ b/ffmpeg.c
> @@ -459,6 +459,7 @@ static void exit_program(void)
>          avcodec_free_frame(&input_streams[i]->decoded_frame);
>          av_dict_free(&input_streams[i]->opts);
>          free_buffer_pool(&input_streams[i]->buffer_pool);
> +        avsubtitle_free(&input_streams[i]->prev_sub.subtitle);
>          avfilter_unref_bufferp(&input_streams[i]->sub2video.ref);
>          av_freep(&input_streams[i]->filters);
>          av_freep(&input_streams[i]);

Ping? I will push soon if nobody objects.

Regards,

-- 
  Nicolas George
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20130224/db3f34c9/attachment.asc>


More information about the ffmpeg-devel mailing list