diff --git a/src/kernel/command.c b/src/kernel/command.c index 13e02ee2e..912f21f7d 100644 --- a/src/kernel/command.c +++ b/src/kernel/command.c @@ -85,19 +85,6 @@ void stree_add(struct syntaxtree *stree, const char *str, parser fun) { addtoken(&stree->root, str, var); } -void -add_command(struct tnode **keys, - const char *str, parser fun) -{ - command *cmd = (command *)malloc(sizeof(command)); - variant var; - - assert(str); - cmd->fun = fun; - var.v = cmd; - addtoken(keys, str, var); -} - static int do_command_i(const struct tnode *keys, struct unit *u, struct order *ord) { char token[128]; diff --git a/src/kernel/command.h b/src/kernel/command.h index 17aa3e949..8fba94b7b 100644 --- a/src/kernel/command.h +++ b/src/kernel/command.h @@ -30,8 +30,6 @@ extern "C" { } syntaxtree; typedef void(*parser) (const void *nodes, struct unit * u, struct order *); - void add_command(struct tnode **troot, - const char *str, parser fun); void do_command(const struct tnode *troot, struct unit *u, struct order *); struct syntaxtree *stree_create(void);