[vlc-devel] [PATCH 2/4] png: fix memory leak
Tristan Matthews
tmatth at videolan.org
Tue Feb 23 20:34:42 CET 2016
On Tue, Feb 23, 2016 at 2:13 PM, Hannes Domani <ssbssa at yahoo.de> wrote:
> ---
> modules/codec/png.c | 5 +----
> 1 file changed, 1 insertion(+), 4 deletions(-)
>
> diff --git a/modules/codec/png.c b/modules/codec/png.c
> index ad2b600..fa46d84 100644
> --- a/modules/codec/png.c
> +++ b/modules/codec/png.c
> @@ -395,9 +395,6 @@ static block_t *EncodeBlock(encoder_t *p_enc, picture_t *p_pic)
> if( p_info == NULL )
> goto error;
>
> - png_infop p_end_info = png_create_info_struct( p_png );
> - if( p_end_info == NULL ) goto error;
> -
> png_set_IHDR( p_png, p_info,
> p_enc->fmt_in.video.i_visible_width,
> p_enc->fmt_in.video.i_visible_height,
> @@ -416,7 +413,7 @@ static block_t *EncodeBlock(encoder_t *p_enc, picture_t *p_pic)
> if( p_sys->b_error ) goto error;
> }
>
> - png_write_end( p_png, p_end_info );
> + png_write_end( p_png, p_info );
> if( p_sys->b_error ) goto error;
>
> png_destroy_write_struct( &p_png, &p_info );
> --
> 2.7.0
>
> _______________________________________________
> vlc-devel mailing list
> To unsubscribe or modify your subscription options:
> https://mailman.videolan.org/listinfo/vlc-devel
LGTM
More information about the vlc-devel
mailing list