diff options
author | lioux <lioux@FreeBSD.org> | 2004-12-29 11:35:40 +0800 |
---|---|---|
committer | lioux <lioux@FreeBSD.org> | 2004-12-29 11:35:40 +0800 |
commit | cb780cbe7b8829808a538cb013f3535115ab23ac (patch) | |
tree | 462a3f97e909367c70d50b3ef99b50ae4af986df /net | |
parent | d2724a3306f616275d235c9d35e4d59887bee0d5 (diff) | |
download | freebsd-ports-gnome-cb780cbe7b8829808a538cb013f3535115ab23ac.tar.gz freebsd-ports-gnome-cb780cbe7b8829808a538cb013f3535115ab23ac.tar.zst freebsd-ports-gnome-cb780cbe7b8829808a538cb013f3535115ab23ac.zip |
o Track BitTorrent's codeville development repository
- BitTorrent/Downloader.py: change (self.active_requests vs
self.backlog) proportion handling
- BitTorrent/download.py: add exception handling around Storage
method call
o Bump PORTREVISION
Obtained from: BitTorrent's codeville repository
Diffstat (limited to 'net')
-rw-r--r-- | net/py-bittorrent-devel/Makefile | 2 | ||||
-rw-r--r-- | net/py-bittorrent-devel/files/patch-BitTorrent::Downloader.py | 11 | ||||
-rw-r--r-- | net/py-bittorrent-devel/files/patch-BitTorrent::download.py | 15 |
3 files changed, 27 insertions, 1 deletions
diff --git a/net/py-bittorrent-devel/Makefile b/net/py-bittorrent-devel/Makefile index 8b3a40481538..c31c2dc04295 100644 --- a/net/py-bittorrent-devel/Makefile +++ b/net/py-bittorrent-devel/Makefile @@ -7,7 +7,7 @@ PORTNAME= BitTorrent PORTVERSION= 3.9.0 -PORTREVISION= 1 +PORTREVISION= 2 PORTEPOCH= 1 CATEGORIES?= net python MASTER_SITES= http://www.bittorrent.com/ diff --git a/net/py-bittorrent-devel/files/patch-BitTorrent::Downloader.py b/net/py-bittorrent-devel/files/patch-BitTorrent::Downloader.py new file mode 100644 index 000000000000..ad747fe9a9e6 --- /dev/null +++ b/net/py-bittorrent-devel/files/patch-BitTorrent::Downloader.py @@ -0,0 +1,11 @@ +--- BitTorrent.orig/Downloader.py Mon Dec 20 20:39:14 2004 ++++ BitTorrent/Downloader.py Wed Dec 29 01:13:08 2004 +@@ -205,7 +205,7 @@ + self.connection.send_interested() + self.example_interest = interest + self.downloader.picker.requested(interest, self.have.numfalse == 0) +- while len(self.active_requests) < self.backlog * 2: ++ while len(self.active_requests) < (self.backlog-2) * 5 + 2: + begin, length = self.downloader.storage.new_request(interest) + self.active_requests.append((interest, begin, length)) + self.connection.send_request(interest, begin, length) diff --git a/net/py-bittorrent-devel/files/patch-BitTorrent::download.py b/net/py-bittorrent-devel/files/patch-BitTorrent::download.py new file mode 100644 index 000000000000..253d305809a4 --- /dev/null +++ b/net/py-bittorrent-devel/files/patch-BitTorrent::download.py @@ -0,0 +1,15 @@ +--- BitTorrent.orig/download.py Mon Dec 20 20:39:15 2004 ++++ BitTorrent/download.py Wed Dec 29 01:13:08 2004 +@@ -144,7 +144,11 @@ + if filelist: + return None + return 1 +- s = Storage(None, None, zip(myfiles, metainfo.sizes), check_only=True) ++ try: ++ s = Storage(None, None, zip(myfiles, metainfo.sizes), ++ check_only=True) ++ except: ++ return None + filename = os.path.join(config['data_dir'], 'resume', + infohash.encode('hex')) + try: |