mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-14 15:47:22 +00:00
Set from even if binfo->extra is NULL.
bgpd/bgp_packet.c:bgp_update_packet(): When extracting the peer, don't fail to extract it because "binfo->extra" is NULL. While one should certainly avoid dereferencing binfo->extra, that's not a good reason not to use binfo->peer. Fixes https://bugzilla.quagga.net/show_bug.cgi?id=497. Patch by Eric Sobocinksi.
This commit is contained in:
parent
cf8a831bcb
commit
d3ddb22e90
@ -177,10 +177,11 @@ bgp_update_packet (struct peer *peer, afi_t afi, safi_t safi)
|
|||||||
|
|
||||||
if (rn->prn)
|
if (rn->prn)
|
||||||
prd = (struct prefix_rd *) &rn->prn->p;
|
prd = (struct prefix_rd *) &rn->prn->p;
|
||||||
if (binfo && binfo->extra)
|
if (binfo)
|
||||||
{
|
{
|
||||||
tag = binfo->extra->tag;
|
|
||||||
from = binfo->peer;
|
from = binfo->peer;
|
||||||
|
if (binfo->extra)
|
||||||
|
tag = binfo->extra->tag;
|
||||||
}
|
}
|
||||||
|
|
||||||
bgp_packet_set_marker (s, BGP_MSG_UPDATE);
|
bgp_packet_set_marker (s, BGP_MSG_UPDATE);
|
||||||
|
Loading…
Reference in New Issue
Block a user