summaryrefslogtreecommitdiffstats
path: root/module/network/HTTPDownload.py
diff options
context:
space:
mode:
authorGravatar RaNaN <Mast3rRaNaN@hotmail.de> 2011-08-18 12:20:21 +0200
committerGravatar RaNaN <Mast3rRaNaN@hotmail.de> 2011-08-18 12:20:21 +0200
commita9f070cebd0af09e9942a595946a2eb84bacde13 (patch)
tree37926f5c3411122ef474b8440520385f4b82c9bf /module/network/HTTPDownload.py
parentforgot to comment line in (diff)
downloadpyload-a9f070cebd0af09e9942a595946a2eb84bacde13.tar.xz
generic multihoster plugin
Diffstat (limited to 'module/network/HTTPDownload.py')
-rw-r--r--module/network/HTTPDownload.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/module/network/HTTPDownload.py b/module/network/HTTPDownload.py
index b5f6313d5..440a3defa 100644
--- a/module/network/HTTPDownload.py
+++ b/module/network/HTTPDownload.py
@@ -151,6 +151,7 @@ class HTTPDownload():
lastTimeCheck = 0
chunksDone = set()
chunksCreated = False
+ done = False
if self.info.getCount() > 1: # This is a resume, if we were chunked originally assume still can
self.chunkSupport=True
@@ -206,9 +207,13 @@ class HTTPDownload():
chunksDone.add(c[0])
if not num_q:
lastFinishCheck = t
+
+ if len(chunksDone) == len(self.chunks):
+ done = True #all chunks loaded
+
break
- if len(chunksDone) == len(self.chunks):
+ if done:
break #all chunks loaded
# calc speed once per second