Allow mixed TLS and non-TLS on same port

Signed-off-by: Derek Collison <derek@nats.io>
This commit is contained in:
Derek Collison
2020-06-05 17:56:37 -07:00
parent ede25f65a6
commit 4dee03b587
13 changed files with 245 additions and 31 deletions

View File

@@ -813,7 +813,7 @@ func (s *Server) createLeafNode(conn net.Conn, remote *leafNodeCfg) *client {
}
// Spin up the read loop.
s.startGoRoutine(func() { c.readLoop() })
s.startGoRoutine(func() { c.readLoop(nil) })
// Spin up the write loop.
s.startGoRoutine(func() { c.writeLoop() })