Commit c90b289c authored by Antoine Cellerier's avatar Antoine Cellerier

When using -p <module name> (or --module <module name>) to look for help, also...

When using -p <module name> (or --module <module name>) to look for help, also check if the module name matches a module's shortcut (and not only the main name). Makes it possible to use stuff like vlc -p udp instead of vlc -p access_udp.
parent 4c5d7ce9
...@@ -1319,7 +1319,15 @@ static void Usage( libvlc_int_t *p_this, char const *psz_module_name ) ...@@ -1319,7 +1319,15 @@ static void Usage( libvlc_int_t *p_this, char const *psz_module_name )
if( psz_module_name && strcmp( psz_module_name, if( psz_module_name && strcmp( psz_module_name,
p_parser->psz_object_name ) ) p_parser->psz_object_name ) )
{ {
continue; char **pp_shortcut = p_parser->pp_shortcuts;
while( *pp_shortcut )
{
if( !strcmp( psz_module_name, *pp_shortcut ) )
break;
pp_shortcut ++;
}
if( !*pp_shortcut )
continue;
} }
/* Ignore modules without config options */ /* Ignore modules without config options */
......
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