up
This commit is contained in:
@ -137,7 +137,9 @@ func (c *TCPClient) ReadLine() {
|
||||
continue
|
||||
}
|
||||
|
||||
if strings.Contains(message, Cfg.Cluster.LoginPrompt+" \r\n") {
|
||||
Log.Debugf("Received Message: %s", message)
|
||||
|
||||
if strings.Contains(message, Cfg.Cluster.LoginPrompt+"\r\n") || strings.Contains(message, Cfg.Cluster.LoginPrompt+" \r\n") {
|
||||
Log.Debug("Found login prompt...sending callsign")
|
||||
c.Write([]byte(c.Login + "\r\n"))
|
||||
time.Sleep(time.Second * 2)
|
||||
@ -154,7 +156,7 @@ func (c *TCPClient) ReadLine() {
|
||||
// Send the spot message to TCP server
|
||||
if len(c.TCPServer.Clients) > 0 {
|
||||
if count == 0 {
|
||||
// wait 3 seconds before sending messages to allow the client to connect
|
||||
// wait 5 seconds before sending messages to allow the client to connect
|
||||
time.Sleep(time.Second * 5)
|
||||
count++
|
||||
}
|
||||
|
Reference in New Issue
Block a user