mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-05-02 13:04:01 +00:00
isisd: Prevent usage after free
Store the vrf_id so that when we free the area we can do further cleanup work. Signed-off-by: Donald Sharp <sharpd@nvidia.com>
This commit is contained in:
parent
7895c3bc4f
commit
f12296baac
@ -80,14 +80,18 @@ int isis_instance_create(struct nb_cb_create_args *args)
|
||||
int isis_instance_destroy(struct nb_cb_destroy_args *args)
|
||||
{
|
||||
struct isis_area *area;
|
||||
vrf_id_t vrf_id;
|
||||
|
||||
if (args->event != NB_EV_APPLY)
|
||||
return NB_OK;
|
||||
area = nb_running_unset_entry(args->dnode);
|
||||
|
||||
vrf_id = area->isis->vrf_id;
|
||||
|
||||
isis_area_destroy(area);
|
||||
|
||||
/* remove ldp-sync config */
|
||||
if (area->isis->vrf_id == VRF_DEFAULT)
|
||||
if (vrf_id == VRF_DEFAULT)
|
||||
isis_ldp_sync_gbl_exit(true);
|
||||
|
||||
return NB_OK;
|
||||
|
Loading…
Reference in New Issue
Block a user