diff options
author | Daniel Walton <dwalton@cumulusnetworks.com> | 2015-10-23 19:34:50 +0200 |
---|---|---|
committer | Daniel Walton <dwalton@cumulusnetworks.com> | 2015-10-23 19:34:50 +0200 |
commit | dd793e4a9c15a9e70bf04560a262b25aeabedc74 (patch) | |
tree | 89825f29a87e65790004b22999bd7f80831de919 /bgpd/bgp_snmp.c | |
parent | Addition of missing zebra command descriptions (diff) | |
download | frr-dd793e4a9c15a9e70bf04560a262b25aeabedc74.tar.xz frr-dd793e4a9c15a9e70bf04560a262b25aeabedc74.zip |
Use a hash to store BGP peer structures
Signed-off-by: Daniel Walton <dwalton@cumulusnetworks.com>
Reviewed-by: Donald Sharp <sharpd@cumulusnetworks.com>
Ticket: CM-5370
Diffstat (limited to 'bgpd/bgp_snmp.c')
-rw-r--r-- | bgpd/bgp_snmp.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/bgpd/bgp_snmp.c b/bgpd/bgp_snmp.c index 0d1aa4df8..5de2bc420 100644 --- a/bgpd/bgp_snmp.c +++ b/bgpd/bgp_snmp.c @@ -311,7 +311,7 @@ bgp_peer_lookup_next (struct in_addr *src) union sockunion su; int ret; - memset (&su, 0, sizeof (union sockunion)); + sockunion_init (&su); bgp = bgp_get_default (); if (! bgp) @@ -621,6 +621,8 @@ bgp4PathAttrLookup (struct variable *v, oid name[], size_t *length, unsigned int len; struct in_addr paddr; + sockunion_init (&su); + #define BGP_PATHATTR_ENTRY_OFFSET \ (IN_ADDR_SIZE + 1 + IN_ADDR_SIZE) |