Commit 2cab85e8 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

avcodec: fix pointer aliasing

av_freep() requires a pointer to void *. Nothing else is defined.
parent 4e54f297
...@@ -341,7 +341,7 @@ static void CloseDecoder( vlc_object_t *p_this ) ...@@ -341,7 +341,7 @@ static void CloseDecoder( vlc_object_t *p_this )
decoder_sys_t *p_sys = p_dec->p_sys; decoder_sys_t *p_sys = p_dec->p_sys;
av_freep( &p_sys->p_context->extradata ); av_free( p_sys->p_context->extradata );
avcodec_free_context( &p_sys->p_context ); avcodec_free_context( &p_sys->p_context );
free( p_sys ); free( p_sys );
} }
......
...@@ -1408,7 +1408,8 @@ void CloseEncoder( vlc_object_t *p_this ) ...@@ -1408,7 +1408,8 @@ void CloseEncoder( vlc_object_t *p_this )
#if (LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(54, 28, 0)) #if (LIBAVCODEC_VERSION_INT >= AV_VERSION_INT(54, 28, 0))
avcodec_free_frame( &p_sys->frame ); avcodec_free_frame( &p_sys->frame );
#else #else
av_freep( &p_sys->frame ); av_free( p_sys->frame );
p_sys->frame = NULL;
#endif #endif
vlc_avcodec_lock(); vlc_avcodec_lock();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment