mirror of
https://gitlab.nic.cz/labs/bird.git
synced 2024-12-22 01:31:55 +00:00
Use ? in path matching to avoid /* trap.
This commit is contained in:
parent
ba1dda495a
commit
9a09a64bb4
@ -139,7 +139,7 @@ WHITE [ \t]
|
||||
return CLI_MARKER;
|
||||
}
|
||||
|
||||
[={}:;,()+*/%-<>~\[\]] {
|
||||
[={}:;,()+*/%-<>~\[\]?] {
|
||||
return yytext[0];
|
||||
}
|
||||
|
||||
|
@ -277,7 +277,7 @@ switch_body: /* EMPTY */ { $$ = NULL; }
|
||||
|
||||
bgp_one:
|
||||
NUM { $$ = $1; }
|
||||
| '*' { $$ = PM_ANY; }
|
||||
| '?' { $$ = PM_ANY; }
|
||||
;
|
||||
|
||||
bgp_path:
|
||||
|
@ -45,8 +45,8 @@ clist l;
|
||||
print "4 = ", p2.len;
|
||||
p2 = prepend( p2, 5 );
|
||||
print "Should be false: ", p2 ~ p;
|
||||
print "Should be true: ", p2 ~ / * 4 3 2 1 /, p2, / * 4 3 2 1 /;
|
||||
print "Should be true: ", p2 ~ / * 4 3 * 1 /, p2, / * 4 3 * 1 /;
|
||||
print "Should be true: ", p2 ~ / ? 4 3 2 1 /, p2, / ? 4 3 2 1 /;
|
||||
print "Should be true: ", p2 ~ / ? 4 3 ? 1 /, p2, / ? 4 3 ? 1 /;
|
||||
print "5 = ", p2.len;
|
||||
|
||||
l = - empty -;
|
||||
|
Loading…
Reference in New Issue
Block a user