Fix false error about wrong stream

- sendinv and sendaddress are sometimes being sent to connections that
  haven't been established yet, resulting in complaints about stream
  mismatch. The error should only be displayed once the connection has
  been established and the remote node provides its stream number
master
Peter Šurda 7 years ago
parent 5ae1327edc
commit 5828021903
Signed by untrusted user: PeterSurda
GPG Key ID: 0C5F50C0B5F37D87

@ -182,8 +182,8 @@ class sendDataThread(threading.Thread):
elif command == 'connectionIsOrWasFullyEstablished':
self.connectionIsOrWasFullyEstablished = True
self.services, self.sslSock = data
else:
logger.error('sendDataThread ID: ' + str(id(self)) + ' ignoring command ' + command + ' because the thread is not in stream' + str(deststream))
elif self.connectionIsOrWasFullyEstablished:
logger.error('sendDataThread ID: ' + str(id(self)) + ' ignoring command ' + command + ' because the thread is not in stream ' + str(deststream))
self.sendDataThreadQueue.task_done()
self.sendDataThreadQueue.task_done()

Loading…
Cancel
Save