From d023aec49f70156d2ed894a8fba65bcfa221ff02 Mon Sep 17 00:00:00 2001 From: Stephen Hemminger Date: Tue, 21 Jul 2009 16:27:21 -0700 Subject: bgpd: start listener on first instance Start BGP listener only after first instance is started. This helps the security if BGP is not used but daemon is started. It also addresses some issues like MD5 not working on listener unless IPV6 configured (because listener was not in list); as well as compiler warnings. * bgp_network.c: (bgp_listener) listen socket creation consolidated here (bgp_socket) Use bgp_listener * bgpd.c: (bgp_get) call bgp_socket on creation of first struct bgp. (bgp_init) remove bgp_socket call. * memtypes.c: Add MTYPE_BGP_LISTENER --- lib/memtypes.c | 1 + 1 file changed, 1 insertion(+) (limited to 'lib') diff --git a/lib/memtypes.c b/lib/memtypes.c index dd365ddb..05d93225 100644 --- a/lib/memtypes.c +++ b/lib/memtypes.c @@ -91,6 +91,7 @@ struct memory_list memory_list_zebra[] = struct memory_list memory_list_bgp[] = { { MTYPE_BGP, "BGP instance" }, + { MTYPE_BGP_LISTENER, "BGP listen socket details" }, { MTYPE_BGP_PEER, "BGP peer" }, { MTYPE_BGP_PEER_HOST, "BGP peer hostname" }, { MTYPE_PEER_GROUP, "Peer group" }, -- cgit v1.2.1