Merge pull request #16617 from FRRouting/mergify/bp/stable/10.1/pr-16608

bgpd: fix crash at no rpki (backport #16608)
This commit is contained in:
Donatas Abraitis 2024-08-22 09:41:17 +02:00 committed by GitHub
commit 1062ff3d0f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -439,7 +439,9 @@ static void rpki_delete_all_cache_nodes(struct rpki_vrf *rpki_vrf)
for (ALL_LIST_ELEMENTS(rpki_vrf->cache_list, cache_node, cache_next,
cache)) {
rtr_mgr_remove_group(rpki_vrf->rtr_config, cache->preference);
if (is_running(rpki_vrf))
rtr_mgr_remove_group(rpki_vrf->rtr_config,
cache->preference);
listnode_delete(rpki_vrf->cache_list, cache);
}
}