diff options
author | Quentin Young <qlyoung@cumulusnetworks.com> | 2016-12-06 20:27:58 +0100 |
---|---|---|
committer | Quentin Young <qlyoung@cumulusnetworks.com> | 2016-12-06 20:27:58 +0100 |
commit | 3d6e734154e6da17423e9054b5443774cacfdd51 (patch) | |
tree | 6aa6003399b7903ef79971317959396f5d49657a /lib/command_match.c | |
parent | lib: add back original ipv6 matcher (diff) | |
download | frr-3d6e734154e6da17423e9054b5443774cacfdd51.tar.xz frr-3d6e734154e6da17423e9054b5443774cacfdd51.zip |
lib, tests: fix failing cli tests
Some tests still failing pending reimplementation of {}
cli definition constructs
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
Diffstat (limited to 'lib/command_match.c')
-rw-r--r-- | lib/command_match.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/command_match.c b/lib/command_match.c index e75910c27..13c890fc0 100644 --- a/lib/command_match.c +++ b/lib/command_match.c @@ -27,6 +27,7 @@ #include "command_match.h" #include "memory.h" + #ifdef TRACE_MATCHER #define TM 1 #else @@ -362,7 +363,8 @@ command_complete (struct graph *graph, input_token, token->text, token->type); unsigned int last_token = (vector_active (vline) - 1 == idx); - switch (match_token (token, input_token)) + enum match_type matchtype = match_token (token, input_token); + switch (matchtype) { // occurs when last token is whitespace case trivial_match: @@ -378,7 +380,7 @@ command_complete (struct graph *graph, trace_matcher ("exact_match\n"); if (last_token) listnode_add (next, gn); - else + else if (matchtype >= minmatch) add_nexthops (next, gn); break; default: |