Commit 0b32594e authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

spu_Create: attach object before calling var_Inherit

parent a7516f02
...@@ -198,9 +198,9 @@ spu_t *spu_Create( vlc_object_t *p_this ) ...@@ -198,9 +198,9 @@ spu_t *spu_Create( vlc_object_t *p_this )
p_spu = vlc_custom_create( p_this, sizeof(spu_t) + sizeof(spu_private_t), p_spu = vlc_custom_create( p_this, sizeof(spu_t) + sizeof(spu_private_t),
VLC_OBJECT_GENERIC, "subpicture" ); VLC_OBJECT_GENERIC, "subpicture" );
if( !p_spu ) if( !p_spu )
return NULL; return NULL;
vlc_object_attach( p_spu, p_this );
/* Initialize spu fields */ /* Initialize spu fields */
p_spu->pf_control = SpuControl; p_spu->pf_control = SpuControl;
...@@ -221,8 +221,6 @@ spu_t *spu_Create( vlc_object_t *p_this ) ...@@ -221,8 +221,6 @@ spu_t *spu_Create( vlc_object_t *p_this )
/* Register the default subpicture channel */ /* Register the default subpicture channel */
p_sys->i_channel = 2; p_sys->i_channel = 2;
vlc_object_attach( p_spu, p_this );
p_sys->psz_chain_update = NULL; p_sys->psz_chain_update = NULL;
p_sys->p_chain = filter_chain_New( p_spu, "sub filter", false, p_sys->p_chain = filter_chain_New( p_spu, "sub filter", false,
SubFilterAllocationInit, SubFilterAllocationInit,
......
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