Make sure connection is added to m.protoConn and m.rawConn before it's Start()ed (fixes #2034)
This commit is contained in:
@@ -983,6 +983,8 @@ func (m *Model) AddConnection(rawConn io.Closer, protoConn protocol.Connection)
|
||||
}
|
||||
m.rawConn[deviceID] = rawConn
|
||||
|
||||
protoConn.Start()
|
||||
|
||||
cm := m.clusterConfig(deviceID)
|
||||
protoConn.ClusterConfig(cm)
|
||||
|
||||
|
||||
@@ -242,6 +242,9 @@ func (FakeConnection) Close() error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (f FakeConnection) Start() {
|
||||
}
|
||||
|
||||
func (f FakeConnection) ID() protocol.DeviceID {
|
||||
return f.id
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user