Package: bittornado
Version: 0.3.18-8
Apparently, the problem described in [1] also exists with the
Debian Lenny bittornado package.
Namely, when IPv6 peers connect to a bttrack(1) instance, a
traceback is written to LOG (see the attached example), with no
peer being able to discover the other.
There's a patch [1] (also attached) that apparently fixes the
problem. The bttrack(1) instance (both before and after
patching) was started like:
$ (cd DIR && bttrack --compact_reqd 0 \
--dfile DFILE --port PORT --ipv6_enabled 1 --ipv6_binds_v4 1 \
< /dev/null > LOG 2>&1) &
The peers were:
$ btdownloadcurses --ipv6_enabled 1 \
TORRENT-FILE
[1] http://www.cs.helsinki.fi/u/sklvarjo/torrent.html
--
FSF associate member #7257
Traceback (most recent call last):
File "/var/lib/python-support/python2.5/BitTornado/RawServer.py", line 144,
in listen_forever
self.sockethandler.handle_events(events)
File "/var/lib/python-support/python2.5/BitTornado/SocketHandler.py", line
319, in handle_events
s.handler.data_came_in(s, data)
File "/var/lib/python-support/python2.5/BitTornado/HTTPHandler.py", line 155,
in data_came_in
if not c.data_came_in(data) and not c.closed:
File "/var/lib/python-support/python2.5/BitTornado/HTTPHandler.py", line 46,
in data_came_in
self.next_func = self.next_func(val)
File "/var/lib/python-support/python2.5/BitTornado/HTTPHandler.py", line 78,
in read_header
r = self.handler.getfunc(self, self.path, self.headers)
File "/var/lib/python-support/python2.5/BitTornado/BT1/track.py", line 951,
in get
return_type, rsize, params('supportcrypto'))
File "/var/lib/python-support/python2.5/BitTornado/BT1/track.py", line 782,
in peerlist
cache = self.cached.setdefault(infohash,[None,None,None])[return_type]
IndexError: list index out of range
--- track.py.orig 2009-07-23 13:51:24.000000000 +0300
+++ track.py 2009-07-23 13:48:51.000000000 +0300
@@ -773,7 +773,10 @@
data['peers'] = []
return data
l_get_size = int(float(rsize)*(len_l)/(len_l+len_s))
- cache = self.cached.setdefault(infohash,[None,None,None])[return_type]
+ if self.config['compact_reqd']:
+ cache = self.cached.setdefault(infohash,[None,None,None])[return_type]
+ else:
+ cache = self.cached.setdefault(infohash,[None,None,None,None,None])[return_type]
if cache and ( not cache[1]
or (is_seed and len(cache[1]) < rsize)
or len(cache[1]) < l_get_size
pgpSm2Od5DD3u.pgp
Description: PGP signature

