diff options
| author | Renato Westphal <renato@opensourcerouting.org> | 2018-05-09 01:35:01 -0300 | 
|---|---|---|
| committer | Renato Westphal <renato@opensourcerouting.org> | 2018-10-27 16:16:12 -0200 | 
| commit | 908f0020923f77545ae467837d78b7eaa91f048e (patch) | |
| tree | c11a91f0fb93c83fb7301e6c5324be8497c6a5a4 /ripd/rip_routemap.c | |
| parent | 44f2f852a18dd4f0b93215f46c1020f04676fa64 (diff) | |
ripd: retrofit the 'redistribute' commands to the new northbound model
Trivial conversion. As usual, combine multiple DEFUNs into a single
DEFPY for simplicity.
As a bonus of the northbound conversion, this commit fixes the
redistribution of certain protocols into ripd. The 'redist_type' array
used by the "redistribute" commands was terribly outdated, which was
preventing the CLI to parse correctly certain protocols like isis
and babel.
Remove the route_map hooks installed by rip_route_map_init() since they
were redundant (rip_init() already takes care of that).
Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
Diffstat (limited to 'ripd/rip_routemap.c')
| -rw-r--r-- | ripd/rip_routemap.c | 19 | 
1 files changed, 0 insertions, 19 deletions
diff --git a/ripd/rip_routemap.c b/ripd/rip_routemap.c index 88473c164e..b69b2466d5 100644 --- a/ripd/rip_routemap.c +++ b/ripd/rip_routemap.c @@ -40,22 +40,6 @@ struct rip_metric_modifier {  	uint8_t metric;  }; -/* Hook function for updating route_map assignment. */ -/* ARGSUSED */ -static void rip_route_map_update(const char *notused) -{ -	int i; - -	if (rip) { -		for (i = 0; i < ZEBRA_ROUTE_MAX; i++) { -			if (rip->route_map[i].name) -				rip->route_map[i].map = -					route_map_lookup_by_name( -						rip->route_map[i].name); -		} -	} -} -  /* `match metric METRIC' */  /* Match function return 1 if match is success else return zero. */  static route_map_result_t route_match_metric(void *rule, @@ -543,9 +527,6 @@ void rip_route_map_init()  {  	route_map_init(); -	route_map_add_hook(rip_route_map_update); -	route_map_delete_hook(rip_route_map_update); -  	route_map_match_interface_hook(generic_match_add);  	route_map_no_match_interface_hook(generic_match_delete);  | 
