bgpd: Fix non v4 EOR parsing

When we receive a non v4 EOR, we were parsing it but
incorrectly applying the test for the flag for it.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Reviewed-by: Daniel Walton <dwalton@cumulusnetworks.com>
This commit is contained in:
Donald Sharp 2016-10-21 14:05:54 -04:00
parent 96e52474fd
commit 18ef625f95

View File

@ -1605,7 +1605,7 @@ bgp_update_receive (struct peer *peer, bgp_size_t size)
afi = AFI_IP;
safi = SAFI_UNICAST;
}
else if (attr.flag == BGP_ATTR_MP_UNREACH_NLRI
else if (attr.flag & ATTR_FLAG_BIT (BGP_ATTR_MP_UNREACH_NLRI)
&& nlris[NLRI_MP_WITHDRAW].length == 0
&& bgp_afi_safi_valid_indices (nlris[NLRI_MP_WITHDRAW].afi,
&nlris[NLRI_MP_WITHDRAW].safi))