[vlc-commits] chroma: chain: fix level variable destroyed twice
Thomas Guillem
git at videolan.org
Tue Jun 6 12:00:53 CEST 2017
vlc | branch: master | Thomas Guillem <thomas at gllm.fr> | Tue Jun 6 12:00:01 2017 +0200| [8ab97dac6749f3f6f18f5c2691d888c452f3f694] | committer: Thomas Guillem
chroma: chain: fix level variable destroyed twice
The level variable can be destroyed just after the filter chain is built.
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=8ab97dac6749f3f6f18f5c2691d888c452f3f694
---
modules/video_chroma/chain.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/modules/video_chroma/chain.c b/modules/video_chroma/chain.c
index 9d418874ea..be4c26e611 100644
--- a/modules/video_chroma/chain.c
+++ b/modules/video_chroma/chain.c
@@ -135,10 +135,11 @@ static int Activate( filter_t *p_filter, int (*pf_build)(filter_t *) )
else
i_ret = pf_build( p_filter );
+ var_Destroy( p_filter, MODULE_STRING "-level" );
+
if( i_ret )
{
/* Hum ... looks like this really isn't going to work. Too bad. */
- var_Destroy( p_filter, MODULE_STRING "-level" );
filter_chain_Delete( p_sys->p_chain );
free( p_sys );
return VLC_EGENERIC;
@@ -182,7 +183,6 @@ static void Destroy( vlc_object_t *p_this )
{
filter_t *p_filter = (filter_t *)p_this;
- var_Destroy( p_filter, MODULE_STRING "-level" );
filter_chain_Delete( p_filter->p_sys->p_chain );
free( p_filter->p_sys );
}
@@ -280,7 +280,6 @@ static int BuildChromaChain( filter_t *p_filter )
break;
}
- var_Destroy( p_filter, MODULE_STRING "-level" );
return i_ret;
}
@@ -333,7 +332,6 @@ static int BuildFilterChain( filter_t *p_filter )
else
filter_chain_Reset( p_filter->p_sys->p_chain, &p_filter->fmt_in, &p_filter->fmt_out );
- var_Destroy( p_filter, MODULE_STRING "-level" );
return i_ret;
}
More information about the vlc-commits
mailing list