diff options
author | ISHIDA Wataru <ishida.wataru@lab.ntt.co.jp> | 2015-07-01 16:55:42 +0900 |
---|---|---|
committer | FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> | 2015-07-01 18:06:56 +0900 |
commit | 4a022a42c62fa3c76424db1323bfdaca4571fdee (patch) | |
tree | c557e5cafaec738bfa2697f795cce3fb7b189ffb /server/peer.go | |
parent | 1adfa485d578af59b653c9b2d141b12a97e89fb7 (diff) |
server: don't set ttl to 1 when peer type is iBGP
Signed-off-by: ISHIDA Wataru <ishida.wataru@lab.ntt.co.jp>
Diffstat (limited to 'server/peer.go')
-rw-r--r-- | server/peer.go | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/server/peer.go b/server/peer.go index 56ce7e17..3e5888f0 100644 --- a/server/peer.go +++ b/server/peer.go @@ -193,6 +193,11 @@ func (peer *Peer) startFSMHandler(incoming chan *fsmMsg) { } func (peer *Peer) PassConn(conn *net.TCPConn) { + isEBGP := peer.globalConfig.As != peer.config.PeerAs + if isEBGP { + ttl := 1 + SetTcpTTLSockopts(conn, ttl) + } select { case peer.fsm.connCh <- conn: default: |