summaryrefslogtreecommitdiffhomepage
path: root/pkg/server
diff options
context:
space:
mode:
authorFUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>2018-11-13 13:09:22 +0900
committerFUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>2018-11-13 13:56:12 +0900
commitb3191fc7a2b8ba4df97ed5d7d2f828042b7e8347 (patch)
tree8d35cd8a4d71a0114ae48f774874b2e73ad07e68 /pkg/server
parent528f75164c3ce664b93cc61fc39a89c744b7c8c2 (diff)
server: unexport BgpServer's Listeners()
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Diffstat (limited to 'pkg/server')
-rw-r--r--pkg/server/server.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/pkg/server/server.go b/pkg/server/server.go
index 75c39739..d42881d1 100644
--- a/pkg/server/server.go
+++ b/pkg/server/server.go
@@ -169,7 +169,7 @@ func NewBgpServer(opt ...ServerOption) *BgpServer {
return s
}
-func (server *BgpServer) Listeners(addr string) []*net.TCPListener {
+func (server *BgpServer) listListeners(addr string) []*net.TCPListener {
list := make([]*net.TCPListener, 0, len(server.listeners))
rhs := net.ParseIP(addr).To4() != nil
for _, l := range server.listeners {
@@ -2581,7 +2581,7 @@ func (server *BgpServer) addNeighbor(c *config.Neighbor) error {
}
if server.bgpConfig.Global.Config.Port > 0 {
- for _, l := range server.Listeners(addr) {
+ for _, l := range server.listListeners(addr) {
if c.Config.AuthPassword != "" {
if err := setTCPMD5SigSockopt(l, addr, c.Config.AuthPassword); err != nil {
log.WithFields(log.Fields{
@@ -2680,7 +2680,7 @@ func (server *BgpServer) deleteNeighbor(c *config.Neighbor, code, subcode uint8)
if !y {
return fmt.Errorf("Can't delete a peer configuration for %s", addr)
}
- for _, l := range server.Listeners(addr) {
+ for _, l := range server.listListeners(addr) {
if err := setTCPMD5SigSockopt(l, addr, ""); err != nil {
log.WithFields(log.Fields{
"Topic": "Peer",