From bf47fe4b2e40ccfcfe6af2d86548d06cdf9739c5 Mon Sep 17 00:00:00 2001 From: Ondrej Zajicek Date: Thu, 26 Nov 2009 20:47:59 +0100 Subject: Implements BGP route refresh. --- proto/bgp/bgp.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'proto/bgp/bgp.c') diff --git a/proto/bgp/bgp.c b/proto/bgp/bgp.c index cde0276..24cd202 100644 --- a/proto/bgp/bgp.c +++ b/proto/bgp/bgp.c @@ -676,6 +676,17 @@ bgp_neigh_notify(neighbor *n) } } +static int +bgp_reload_routes(struct proto *P) +{ + struct bgp_proto *p = (struct bgp_proto *) P; + if (!p->conn || !p->conn->peer_refresh_support) + return 0; + + bgp_schedule_packet(p->conn, PKT_ROUTE_REFRESH); + return 1; +} + static void bgp_start_locked(struct object_lock *lock) { @@ -792,6 +803,7 @@ bgp_init(struct proto_config *C) P->rte_better = bgp_rte_better; P->import_control = bgp_import_control; P->neigh_notify = bgp_neigh_notify; + P->reload_routes = bgp_reload_routes; p->cf = c; p->local_as = c->local_as; p->remote_as = c->remote_as; -- cgit v1.2.3