Add connection before init, so init happens before polling of events
This commit is contained in:
parent
8bbaa6df18
commit
be78d498dc
|
@ -825,9 +825,10 @@ open class Client<CONNECTION : Connection>(config: ClientConfiguration = ClientC
|
|||
listenerManager.notifyInit(newConnection)
|
||||
}
|
||||
|
||||
connection0 = newConnection
|
||||
// this enables the connection to start polling for messages
|
||||
addConnection(newConnection)
|
||||
|
||||
connection0 = newConnection
|
||||
|
||||
// if we shutdown/close before the poller starts, we don't want to block forever
|
||||
pollerClosedLatch = CountDownLatch(1)
|
||||
networkEventPoller.submit(
|
||||
|
|
|
@ -146,7 +146,6 @@ internal class ServerHandshake<CONNECTION : Connection>(
|
|||
listenerManager.notifyInit(newConnection)
|
||||
}
|
||||
|
||||
|
||||
// this enables the connection to start polling for messages
|
||||
server.addConnection(newConnection)
|
||||
|
||||
|
|
Loading…
Reference in New Issue