From 4215e8011b52abaccc96198cb8fa6d7034521dc9 Mon Sep 17 00:00:00 2001 From: Donald Sharp Date: Fri, 21 Jul 2023 12:46:31 -0400 Subject: [PATCH] bgpd: Remove withdraw_low from system, it is never used Signed-off-by: Donald Sharp --- bgpd/bgp_advertise.h | 1 - bgpd/bgp_updgrp.c | 2 +- bgpd/bgp_updgrp.h | 6 ++---- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/bgpd/bgp_advertise.h b/bgpd/bgp_advertise.h index c461f231b4..a063208b6d 100644 --- a/bgpd/bgp_advertise.h +++ b/bgpd/bgp_advertise.h @@ -100,7 +100,6 @@ struct bgp_adj_in { struct bgp_synchronize { struct bgp_adv_fifo_head update; struct bgp_adv_fifo_head withdraw; - struct bgp_adv_fifo_head withdraw_low; }; /* BGP adjacency linked list. */ diff --git a/bgpd/bgp_updgrp.c b/bgpd/bgp_updgrp.c index 849f669932..a55e48d8ed 100644 --- a/bgpd/bgp_updgrp.c +++ b/bgpd/bgp_updgrp.c @@ -74,7 +74,7 @@ static void sync_init(struct update_subgroup *subgrp, XCALLOC(MTYPE_BGP_SYNCHRONISE, sizeof(struct bgp_synchronize)); bgp_adv_fifo_init(&subgrp->sync->update); bgp_adv_fifo_init(&subgrp->sync->withdraw); - bgp_adv_fifo_init(&subgrp->sync->withdraw_low); + subgrp->hash = hash_create(bgp_advertise_attr_hash_key, bgp_advertise_attr_hash_cmp, "BGP SubGroup Hash"); diff --git a/bgpd/bgp_updgrp.h b/bgpd/bgp_updgrp.h index 70e7ac30b5..0d866f3be7 100644 --- a/bgpd/bgp_updgrp.h +++ b/bgpd/bgp_updgrp.h @@ -584,11 +584,9 @@ static inline void bgp_announce_peer(struct peer *peer) */ static inline int advertise_list_is_empty(struct update_subgroup *subgrp) { - if (bgp_adv_fifo_count(&subgrp->sync->update) - || bgp_adv_fifo_count(&subgrp->sync->withdraw) - || bgp_adv_fifo_count(&subgrp->sync->withdraw_low)) { + if (bgp_adv_fifo_count(&subgrp->sync->update) || + bgp_adv_fifo_count(&subgrp->sync->withdraw)) return 0; - } return 1; } -- 2.39.5