diff options
Diffstat (limited to 'wrapper/runcom.c')
-rw-r--r-- | wrapper/runcom.c | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/wrapper/runcom.c b/wrapper/runcom.c index 10e9919..5928bb3 100644 --- a/wrapper/runcom.c +++ b/wrapper/runcom.c @@ -40,7 +40,20 @@ main ( int argc, char *argv[] ) struct plugin *plugins; plugins=load_plugins(stdin); struct plugin_command_list *list; - list=plugin_find_commands(plugins,argv[1]); + if ( strchr(argv[1],'/') == NULL ) + list=plugin_find_commands(plugins,argv[1]); + else { + /* this is a command for a specific plugin */ + list=xmalloc(sizeof(*list)); + list->command=plugin_depend_parse(stralloc(argv[1])); + list->next=NULL; + if ( list->command == NULL ) { + /* plugin_depend_parse should fail the program*\ + \* on its own, but just to be safe... */ + plugin_free_list(list); + list=NULL; + } + } if (list==NULL) error(EXIT_FAILURE,0,"unrecognized command `%s'", argv[1]); |