summaryrefslogtreecommitdiff
path: root/lib/grammar_sandbox.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/grammar_sandbox.c')
-rw-r--r--lib/grammar_sandbox.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/lib/grammar_sandbox.c b/lib/grammar_sandbox.c
index f35b8beffd..24bf20dac6 100644
--- a/lib/grammar_sandbox.c
+++ b/lib/grammar_sandbox.c
@@ -70,11 +70,11 @@ DEFUN (grammar_test,
// parse the command and install it into the command graph
struct graph *graph = graph_new();
- struct cmd_token *token = new_cmd_token (START_TKN, CMD_ATTR_NORMAL, NULL, NULL);
- graph_new_node (graph, token, (void (*)(void *)) &del_cmd_token);
+ struct cmd_token *token = cmd_token_new (START_TKN, CMD_ATTR_NORMAL, NULL, NULL);
+ graph_new_node (graph, token, (void (*)(void *)) &cmd_token_del);
- command_parse_format (graph, cmd);
- cmd_merge_graphs (nodegraph, graph, +1);
+ cmd_graph_parse (graph, cmd);
+ cmd_graph_merge (nodegraph, graph, +1);
return CMD_SUCCESS;
}
@@ -123,7 +123,7 @@ DEFUN (grammar_test_complete,
}
for (i = 0; i < vector_active (comps); i++)
- del_cmd_token ((struct cmd_token *) vector_slot (comps, i));
+ cmd_token_del ((struct cmd_token *) vector_slot (comps, i));
vector_free (comps);
}
else
@@ -229,7 +229,7 @@ DEFUN (grammar_test_doc,
cmd->func = NULL;
// parse element
- command_parse_format (nodegraph, cmd);
+ cmd_graph_parse (nodegraph, cmd);
return CMD_SUCCESS;
}
@@ -649,8 +649,8 @@ init_cmdgraph (struct vty *vty, struct graph **graph)
// initialize graph, add start noe
*graph = graph_new ();
nodegraph_free = *graph;
- struct cmd_token *token = new_cmd_token (START_TKN, 0, NULL, NULL);
- graph_new_node (*graph, token, (void (*)(void *)) &del_cmd_token);
+ struct cmd_token *token = cmd_token_new (START_TKN, 0, NULL, NULL);
+ graph_new_node (*graph, token, (void (*)(void *)) &cmd_token_del);
if (vty)
vty_out (vty, "initialized graph%s", VTY_NEWLINE);
}