diff options
author | Ondrej Zajicek (work) <santiago@crfreenet.org> | 2015-11-12 02:03:59 +0100 |
---|---|---|
committer | Ondrej Zajicek (work) <santiago@crfreenet.org> | 2015-11-12 02:03:59 +0100 |
commit | d44e686e9bcae5850115c0e1adfe24523dce61ee (patch) | |
tree | 88feb4c9e43fe547db954496ec5d9eb66b307f52 /proto/static/config.Y | |
parent | fe9f1a6dedda6bab23cbb605d1cd5db6cd3e2468 (diff) |
Follow-up commit on integrated BIRD
Use net_addr for interface address prefixes, support net_addr in
configuration parser.
Diffstat (limited to 'proto/static/config.Y')
-rw-r--r-- | proto/static/config.Y | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/proto/static/config.Y b/proto/static/config.Y index 182721b3..9e634803 100644 --- a/proto/static/config.Y +++ b/proto/static/config.Y @@ -52,11 +52,10 @@ static_proto: | static_proto stat_route stat_route_opt_list ';' { static_route_finish(); } ; -stat_route0: ROUTE prefix { +stat_route0: ROUTE net_any { this_srt = cfg_allocz(sizeof(struct static_route)); add_tail(&STATIC_CFG->other_routes, &this_srt->n); - this_srt->net = $2.addr; - this_srt->masklen = $2.len; + this_srt->net = $2; this_srt_last_cmd = &(this_srt->cmds); } ; @@ -72,7 +71,7 @@ stat_multipath1: this_srt_nh->use_bfd = -1; /* undefined */ } | stat_multipath1 WEIGHT expr { - this_srt_nh->masklen = $3 - 1; /* really */ + this_srt_nh->weight = $3 - 1; if (($3<1) || ($3>256)) cf_error("Weight must be in range 1-256"); } | stat_multipath1 BFD bool { |