fix connection for ipv6

This commit is contained in:
Yann Leboulanger 2008-07-03 06:26:39 +00:00
parent 952e4a1569
commit f379d06d2c
1 changed files with 2 additions and 2 deletions

View File

@ -149,8 +149,8 @@ class NonBlockingTcp(PlugIn, IdleObject):
''' '''
self.on_connect = on_connect self.on_connect = on_connect
self.on_connect_failure = on_connect_failure self.on_connect_failure = on_connect_failure
(self.server, self.port) = conn_5tuple[4] (self.server, self.port) = conn_5tuple[4][:2]
log.info('NonBlocking Connect :: About tot connect to %s:%s' % conn_5tuple[4]) log.info('NonBlocking Connect :: About tot connect to %s:%s' % conn_5tuple[4][:2])
try: try:
self._sock = socket.socket(*conn_5tuple[:3]) self._sock = socket.socket(*conn_5tuple[:3])
except socket.error, (errnum, errstr): except socket.error, (errnum, errstr):