diff options
author | RaNaN <Mast3rRaNaN@hotmail.de> | 2010-12-19 19:59:45 +0100 |
---|---|---|
committer | RaNaN <Mast3rRaNaN@hotmail.de> | 2010-12-19 19:59:45 +0100 |
commit | 34a5b4372aa6e50c072a568c564d6d492743c508 (patch) | |
tree | b7ace2ebd3511b4165cccfb6b44d96c60963dc14 /module/network/HTTPDownload.py | |
parent | corrected byte range on resume (diff) | |
download | pyload-34a5b4372aa6e50c072a568c564d6d492743c508.tar.xz |
some adjusments
Diffstat (limited to 'module/network/HTTPDownload.py')
-rw-r--r-- | module/network/HTTPDownload.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/module/network/HTTPDownload.py b/module/network/HTTPDownload.py index fed99ae23..d0e2eeb1f 100644 --- a/module/network/HTTPDownload.py +++ b/module/network/HTTPDownload.py @@ -261,7 +261,7 @@ class HTTPDownload(): self.info.save() dg.addCallback(self._copyChunks) - if len(self.chunks) == 0: + if not len(self.chunks): dg.callback() return self.deferred else: @@ -272,9 +272,9 @@ if __name__ == "__main__": from Bucket import Bucket bucket = Bucket() bucket.setRate(200*1024) - #bucket = None + bucket = None - url = "http://speedtest.netcologne.de/test_10mb.bin" + url = "http://speedtest.netcologne.de/test_100mb.bin" finished = False def err(*a, **b): @@ -286,7 +286,7 @@ if __name__ == "__main__": print "starting" - dwnld = HTTPDownload(url, "test_10mb.bin", bucket=bucket) + dwnld = HTTPDownload(url, "test_100mb.bin", bucket=bucket) d = dwnld.download(chunks=5, resume=True) d.addCallback(callb) d.addErrback(err) |