Use one stream in version message for inbound connections
This commit is contained in:
parent
242a161585
commit
45508538aa
|
@ -542,10 +542,15 @@ class BMProto(AdvancedDispatcher, ObjectTracker):
|
|||
if not ua_valid:
|
||||
self.userAgent = '/INVALID:0/'
|
||||
if not self.isOutbound:
|
||||
common_streams = self.streams.intersection(
|
||||
connectionpool.BMConnectionPool().streams)
|
||||
try: # leave one because of bug in decode_payload_content()
|
||||
common_streams = [min(common_streams)]
|
||||
except ValueError:
|
||||
common_streams = [1]
|
||||
self.append_write_buf(protocol.assembleVersionMessage(
|
||||
self.destination.host, self.destination.port,
|
||||
connectionpool.BMConnectionPool().streams, True,
|
||||
nodeid=self.nodeid))
|
||||
common_streams, True, nodeid=self.nodeid))
|
||||
logger.debug(
|
||||
'%(host)s:%(port)i sending version',
|
||||
self.destination._asdict())
|
||||
|
|
Reference in New Issue
Block a user