Commit de20ea8f authored by Antoine Cellerier's avatar Antoine Cellerier

Use the module's name as object name if none was explicitly given by the user.

parent c256e739
...@@ -711,11 +711,16 @@ found_shortcut: ...@@ -711,11 +711,16 @@ found_shortcut:
else else
msg_StackSet( VLC_EGENERIC, "no suitable %s module", psz_capability ); msg_StackSet( VLC_EGENERIC, "no suitable %s module", psz_capability );
if( psz_alias && !p_this->psz_object_name ) if( p_module && !p_this->psz_object_name )
{
/* This assumes that p_this is the object which will be using the /* This assumes that p_this is the object which will be using the
* module. That's not always the case ... but it is in most cases. * module. That's not always the case ... but it is in most cases.
*/ */
p_this->psz_object_name = strdup( psz_alias ); if( psz_alias )
p_this->psz_object_name = strdup( psz_alias );
else
p_this->psz_object_name = strdup( p_module->psz_object_name );
}
if( psz_shortcuts ) if( psz_shortcuts )
{ {
......
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