Skip to content

Commit

Permalink
Merge pull request FRRouting#18045 from LabNConsulting/ziemba/250205-…
Browse files Browse the repository at this point in the history
…rfapi-mem-cleanup

bgpd: rfapi: fix mem leak when killed
  • Loading branch information
donaldsharp authored Feb 7, 2025
2 parents 4527320 + 125a480 commit eebe460
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions bgpd/rfapi/rfapi_import.c
Original file line number Diff line number Diff line change
Expand Up @@ -4067,9 +4067,15 @@ static void rfapiProcessPeerDownRt(struct peer *peer,
bpi, import_table, afi, -1);
import_table->holddown_count[afi] += 1;
}
rfapiBiStartWithdrawTimer(import_table, rn, bpi,
afi, safi,
timer_service_func);
if (bm->terminating) {
if (safi == SAFI_MPLS_VPN)
rfapiExpireVpnNow(import_table, rn, bpi, 1);
else
rfapiExpireEncapNow(import_table, rn, bpi);

} else
rfapiBiStartWithdrawTimer(import_table, rn, bpi, afi, safi,
timer_service_func);
}
}
}
Expand Down

0 comments on commit eebe460

Please sign in to comment.