diff --git a/bgpd/bgp_packet.c b/bgpd/bgp_packet.c index 5dc35157ebf6..601dac7970c6 100644 --- a/bgpd/bgp_packet.c +++ b/bgpd/bgp_packet.c @@ -3339,8 +3339,6 @@ static void bgp_dynamic_capability_fqdn(uint8_t *pnt, int action, data += len; if (len) { - str[len] = '\0'; - XFREE(MTYPE_BGP_PEER_HOST, peer->domainname); peer->domainname = XSTRDUP(MTYPE_BGP_PEER_HOST, str);