From f0ae221b894fdd02f697f4fb6994623082e2175e Mon Sep 17 00:00:00 2001 From: FUJITA Tomonori Date: Tue, 3 Mar 2015 12:23:43 +0900 Subject: update the whole code for the latest openconfig yang files The modified openconfig yang files are available at: https://github.com/osrg/yang/tree/gobgp Signed-off-by: FUJITA Tomonori --- server/peer.go | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'server/peer.go') diff --git a/server/peer.go b/server/peer.go index 4e8f4ae8..02956788 100644 --- a/server/peer.go +++ b/server/peer.go @@ -47,8 +47,8 @@ type peerMsg struct { type Peer struct { t tomb.Tomb - globalConfig config.GlobalType - peerConfig config.NeighborType + globalConfig config.Global + peerConfig config.Neighbor acceptedConnCh chan net.Conn serverMsgCh chan *serverMsg peerMsgCh chan *peerMsg @@ -65,7 +65,7 @@ type Peer struct { outgoing chan *bgp.BGPMessage } -func NewPeer(g config.GlobalType, peer config.NeighborType, serverMsgCh chan *serverMsg, peerMsgCh chan *peerMsg, peerList []*serverMsgDataPeer) *Peer { +func NewPeer(g config.Global, peer config.Neighbor, serverMsgCh chan *serverMsg, peerMsgCh chan *peerMsg, peerList []*serverMsgDataPeer) *Peer { p := &Peer{ globalConfig: g, peerConfig: peer, @@ -221,7 +221,7 @@ func (peer *Peer) handleREST(restReq *api.RestRequest) { case api.REQ_NEIGHBOR_SHUTDOWN: peer.outgoing <- bgp.NewBGPNotificationMessage(bgp.BGP_ERROR_CEASE, bgp.BGP_ERROR_SUB_ADMINISTRATIVE_SHUTDOWN, nil) case api.REQ_NEIGHBOR_RESET: - peer.fsm.idleHoldTime = peer.peerConfig.Timers.IdleHoldTImeAfterReset + peer.fsm.idleHoldTime = peer.peerConfig.Timers.IdleHoldTimeAfterReset peer.outgoing <- bgp.NewBGPNotificationMessage(bgp.BGP_ERROR_CEASE, bgp.BGP_ERROR_SUB_ADMINISTRATIVE_RESET, nil) case api.REQ_NEIGHBOR_SOFT_RESET, api.REQ_NEIGHBOR_SOFT_RESET_IN: // soft-reconfiguration inbound @@ -410,7 +410,7 @@ func (peer *Peer) loop() error { // clear counter if h.fsm.adminState == ADMIN_STATE_DOWN { - h.fsm.peerConfig.BgpNeighborCommonState = config.BgpNeighborCommonStateType{} + h.fsm.peerConfig.BgpNeighborCommonState = config.BgpNeighborCommonState{} } case FSM_MSG_BGP_MESSAGE: -- cgit v1.2.3