ipsec: fix use-after-free

Type: fix

Change-Id: I1068ff1d03883addb5fe1005a8b608eab17e4168
Signed-off-by: Benoît Ganne <bganne@cisco.com>
This commit is contained in:
Benoît Ganne
2020-04-16 12:40:04 +02:00
committed by Neale Ranns
parent 77100efb37
commit ea9bc28592

View File

@ -817,8 +817,8 @@ static void
ipsec_tun_protect_adj_delegate_adj_deleted (adj_delegate_t * ad)
{
/* remove our delegate */
adj_delegate_remove (ad->ad_adj_index, ipsec_tun_adj_delegate_type);
ipsec_tun_protect_add_adj (ad->ad_adj_index, INDEX_INVALID);
adj_delegate_remove (ad->ad_adj_index, ipsec_tun_adj_delegate_type);
}
static void