]> git.puffer.fish Git - mirror/frr.git/commit
bgpd: fix aspath memleak on error in vnc_direct_bgp_add_nve 10553/head
authorIgor Ryzhov <iryzhov@nfware.com>
Wed, 9 Feb 2022 22:23:41 +0000 (01:23 +0300)
committermergify-bot <noreply@mergify.com>
Thu, 10 Feb 2022 06:53:50 +0000 (06:53 +0000)
commit955cc29fb604e456184efaf73b6719ce66c614ee
tree4ae985dfb24fe43741de74b534488a4028b497ee
parent2dc64494daacaae39b455391dc4cebc360655f20
bgpd: fix aspath memleak on error in vnc_direct_bgp_add_nve

bgp_attr_default_set creates a new empty aspath. If family error happens,
this aspath is not freed. Move attr initialization after we checked the
family.

Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
(cherry picked from commit 606c3f9fb2e164ea3f2fe87b46f99c4be44104bc)
bgpd/rfapi/vnc_export_bgp.c