From 7e1c219ea1640884de6a7548ce2da878e276d78e Mon Sep 17 00:00:00 2001 From: FUJITA Tomonori Date: Fri, 16 Jan 2015 16:34:38 +0900 Subject: server: send proper notification when the config is deleted Signed-off-by: FUJITA Tomonori --- server/peer.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'server') diff --git a/server/peer.go b/server/peer.go index 6f0d2f6b..437ea38c 100644 --- a/server/peer.go +++ b/server/peer.go @@ -259,7 +259,8 @@ func (peer *Peer) loop() error { select { case <-peer.t.Dying(): close(peer.acceptedConnCh) - h.Stop() + h.fsm.outgoing <- bgp.NewBGPNotificationMessage(bgp.BGP_ERROR_CEASE, bgp.BGP_ERROR_SUB_PEER_DECONFIGURED, nil) + h.Wait() close(peer.incoming) close(peer.outgoing) return nil -- cgit v1.2.3