diff options
| author | Carmine Scarpitta <carmine.scarpitta@uniroma2.it> | 2023-06-10 09:30:17 +0200 | 
|---|---|---|
| committer | Carmine Scarpitta <carmine.scarpitta@uniroma2.it> | 2023-09-11 17:35:04 +0200 | 
| commit | 7064d8a7276e1ec23b568edcf35bd36a27d953d8 (patch) | |
| tree | c31ce2d994e2e07115d171c9716acc7e3e41b8bf /isisd/isis_zebra.c | |
| parent | d8905151946e1e4709f44b4fbb8b295eb3a4df27 (diff) | |
isisd: Uninstall routes only if installed
In some cases, IS-IS may attempt to remove routes that have not been
installed before. We can prevent IS-IS from doing this by aborting
`isis_zebra_route_del_route` when the ISIS_ROUTE_FLAG_ZEBRA_SYNCED flag
is unset, meaning that the route is not installed in the kernel.
Signed-off-by: Carmine Scarpitta <carmine.scarpitta@uniroma2.it>
Diffstat (limited to 'isisd/isis_zebra.c')
| -rw-r--r-- | isisd/isis_zebra.c | 3 | 
1 files changed, 3 insertions, 0 deletions
diff --git a/isisd/isis_zebra.c b/isisd/isis_zebra.c index 4813173f45..1706d27a3a 100644 --- a/isisd/isis_zebra.c +++ b/isisd/isis_zebra.c @@ -308,6 +308,9 @@ void isis_zebra_route_del_route(struct isis *isis,  	if (zclient->sock < 0)  		return; +	if (!CHECK_FLAG(route_info->flag, ISIS_ROUTE_FLAG_ZEBRA_SYNCED)) +		return; +  	memset(&api, 0, sizeof(api));  	api.vrf_id = isis->vrf_id;  	api.type = PROTO_TYPE;  | 
