Commit 98f51bc5 authored by Pierre d'Herbemont's avatar Pierre d'Herbemont

variables: Fix two typos in InheritValue().

First one is about starting to inherit from the parent. Shouldn't hurt much.
Second one is about looking to inherit from the right variable. hurt more.
parent b75f85e4
...@@ -1404,8 +1404,8 @@ static int InheritValue( vlc_object_t *p_this, const char *psz_name, ...@@ -1404,8 +1404,8 @@ static int InheritValue( vlc_object_t *p_this, const char *psz_name,
vlc_value_t *p_val, int i_type ) vlc_value_t *p_val, int i_type )
{ {
i_type &= VLC_VAR_CLASS; i_type &= VLC_VAR_CLASS;
for( vlc_object_t *obj = p_this; obj != NULL; obj = obj->p_parent ) for( vlc_object_t *obj = p_this->p_parent; obj != NULL; obj = obj->p_parent )
if( var_GetChecked( p_this, psz_name, i_type, p_val ) == VLC_SUCCESS ) if( var_GetChecked( obj, psz_name, i_type, p_val ) == VLC_SUCCESS )
return VLC_SUCCESS; return VLC_SUCCESS;
/* else take value from config */ /* else take value from config */
......
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