Quentin Young
de9d7e4f3c
lib: Cleanup some memory issues in CLI
...
Various memory leaks have been fixed and the quagga
memory macros are in use. Also consolidated the argv
and matching code into one graph traversal.
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2016-07-29 15:54:03 +00:00
Quentin Young
5a5d576b34
lib: Cleanup parser memory management
...
Free as appropriate. Additionally add new type
of node to demark graph head (START_GN).
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2016-07-27 04:17:51 +00:00
Quentin Young
eceb106640
lib: Add matching and argv support
...
Queries may be run against DFA's to find matching
cmd_element, and argument lists may be constructed.
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2016-07-27 01:35:46 +00:00
Quentin Young
a53fbbf5f0
lib: Incremental matching improvement
...
Shotgun changes to matching system
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2016-07-26 14:02:36 +00:00
Quentin Young
880e24a1e4
lib: Reorganize some matching stuff
...
Introduce new node type, END_GN, and remove
is_leaf flags. Reorganize command_match.c & remove
internal functions from command_match.h. Start
rewriting command.h in command_new.h with changes
for new backend.
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2016-07-22 19:04:16 +00:00
Quentin Young
18be0e599d
lib: Mostly complete matcher
...
Input matching and completions works. Still some
rough edges.
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2016-07-21 21:38:03 +00:00
Quentin Young
9d0662e009
lib: Break up functions, begin matcher
...
Moved test hook out of command.c into vtysh.c,
renamed graph modules, added matching code
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2016-07-19 21:14:27 +00:00
Quentin Young
340a2b4ac0
lib: Implement node comparison function
...
Implement comparator for nodes, some miscellaneous cleanup.
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2016-07-19 17:06:11 +00:00
Quentin Young
4b0abf2434
lib: Fix some DFA construction bugs
...
Options get null paths, parser state is properly
cleaned up, caller passes start node
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2016-07-18 16:16:36 +00:00
Quentin Young
478bdaeb3b
lib: Finish implementing grammar, DFA construction
...
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2016-07-17 21:49:16 +00:00
Quentin Young
2a23ca6e52
lib: Change some includes
...
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
2016-07-12 15:05:06 +00:00