]> git.proxmox.com Git - mirror_frr.git/blobdiff - bgpd/bgp_debug.c
bgpd: fix valgrind flagged errors
[mirror_frr.git] / bgpd / bgp_debug.c
index c7fad29cb02f85e3f330b00e99aa0c6b8b3a8889..39ba404f384eebe2c70c81d29de33546161e303d 100644 (file)
@@ -368,6 +368,8 @@ int bgp_dump_attr(struct attr *attr, char *buf, size_t size)
        if (!attr)
                return 0;
 
+       buf[0] = '\0';
+
        if (CHECK_FLAG(attr->flag, ATTR_FLAG_BIT(BGP_ATTR_NEXT_HOP)))
                snprintf(buf, size, "nexthop %s", inet_ntoa(attr->nexthop));