diff --git a/bgpd/bgp_packet.c b/bgpd/bgp_packet.c index 60f1dcbcd6..a02d548941 100644 --- a/bgpd/bgp_packet.c +++ b/bgpd/bgp_packet.c @@ -1983,7 +1983,7 @@ static int bgp_update_receive(struct peer *peer, bgp_size_t size) /* Network Layer Reachability Information. */ update_len = end - stream_pnt(s); - if (update_len) { + if (update_len && attribute_len) { /* Set NLRI portion to structure. */ nlris[NLRI_UPDATE].afi = AFI_IP; nlris[NLRI_UPDATE].safi = SAFI_UNICAST;