From: David Lamparter Date: Thu, 7 Sep 2017 13:31:00 +0000 (+0200) Subject: bgpd: fix compiler warning X-Git-Tag: frr-4.0-dev~327^2 X-Git-Url: https://git.puffer.fish/?a=commitdiff_plain;h=be054588b43a222a128840011259b5f8e6c8a2cd;p=mirror%2Ffrr.git bgpd: fix compiler warning bgp_route.c:6393:7: error: ‘len’ may be used uninitialized in this function gcc 5.4.0 isn't intelligent enough to notice it's set on all paths. Signed-off-by: David Lamparter --- diff --git a/bgpd/bgp_route.c b/bgpd/bgp_route.c index f354071654..fabe4483e5 100644 --- a/bgpd/bgp_route.c +++ b/bgpd/bgp_route.c @@ -6339,7 +6339,7 @@ void bgp_redistribute_withdraw(struct bgp *bgp, afi_t afi, int type, static void route_vty_out_route(struct prefix *p, struct vty *vty, json_object *json) { - int len; + int len = 0; u_int32_t destination; char buf[BUFSIZ];