Merge pull request #267 from lbryio/fix-dht-ports

Restore reactor.iterate in dht shutdown
This commit is contained in:
Job Evers‐Meltzer 2016-11-11 11:42:43 -06:00 committed by GitHub
commit a7589914d0

View file

@ -321,3 +321,7 @@ class KademliaProtocol(protocol.DatagramProtocol):
except Exception, e:
log.exception('Failed to cancel %s', self._callLaterList[key])
del self._callLaterList[key]
# not sure why this is needed, but taking this out sometimes causes
# exceptions.AttributeError: 'Port' object has no attribute 'socket'
# to happen on shutdown
reactor.iterate()