summaryrefslogtreecommitdiff
path: root/nest/config.Y
diff options
context:
space:
mode:
authorOndrej Filip <feela@network.cz>2012-04-26 17:03:53 +0200
committerOndrej Filip <feela@network.cz>2012-04-26 17:03:53 +0200
commit1f85226ecb76d3803b8fe37eb0891c45a6557dcd (patch)
treeb0e51334e0f5a788a7203a22e19b7069806c6a47 /nest/config.Y
parent92f8f7e3a3a5a42768c18c1f3d4d8f9f98150c61 (diff)
parentd9b77cc28115e5c1ef64c69722c9d1fd1392dcd1 (diff)
Merge branch 'master' of ssh://git.nic.cz/bird
Diffstat (limited to 'nest/config.Y')
-rw-r--r--nest/config.Y14
1 files changed, 8 insertions, 6 deletions
diff --git a/nest/config.Y b/nest/config.Y
index 60b03278..c59319cb 100644
--- a/nest/config.Y
+++ b/nest/config.Y
@@ -179,6 +179,7 @@ proto_item:
| IMPORT imexport { this_proto->in_filter = $2; }
| EXPORT imexport { this_proto->out_filter = $2; }
| IMPORT LIMIT limit_spec { this_proto->in_limit = $3; }
+ | EXPORT LIMIT limit_spec { this_proto->out_limit = $3; }
| TABLE rtable { this_proto->table = $2; }
| ROUTER ID idval { this_proto->router_id = $3; }
| DESCRIPTION TEXT { this_proto->dsc = $2; }
@@ -192,17 +193,18 @@ imexport:
;
limit_action:
- WARN { $$ = PLA_WARN; }
- | BLOCK { $$ = PLA_BLOCK; }
- | RESTART { $$ = PLA_RESTART; }
- | DISABLE { $$ = PLA_DISABLE; }
+ /* default */ { $$ = PLA_DISABLE; }
+ | EXCEED WARN { $$ = PLA_WARN; }
+ | EXCEED BLOCK { $$ = PLA_BLOCK; }
+ | EXCEED RESTART { $$ = PLA_RESTART; }
+ | EXCEED DISABLE { $$ = PLA_DISABLE; }
;
limit_spec:
- expr EXCEED limit_action {
+ expr limit_action {
struct proto_limit *l = cfg_allocz(sizeof(struct proto_limit));
l->limit = $1;
- l->action = $3;
+ l->action = $2;
$$ = l;
}
;