mirror of
https://github.com/yt-dlp/yt-dlp.git
synced 2024-12-14 23:32:33 +00:00
Do not use 0% as the starting point in resumed downloads (closes #40)
This commit is contained in:
parent
f83ae7816b
commit
106d091e80
1 changed files with 3 additions and 1 deletions
|
@ -606,8 +606,10 @@ class FileDownloader(object):
|
||||||
return False
|
return False
|
||||||
|
|
||||||
data_len = data.info().get('Content-length', None)
|
data_len = data.info().get('Content-length', None)
|
||||||
|
if data_len is not None:
|
||||||
|
data_len = long(data_len) + resume_len
|
||||||
data_len_str = self.format_bytes(data_len)
|
data_len_str = self.format_bytes(data_len)
|
||||||
byte_counter = 0
|
byte_counter = 0 + resume_len
|
||||||
block_size = 1024
|
block_size = 1024
|
||||||
start = time.time()
|
start = time.time()
|
||||||
while True:
|
while True:
|
||||||
|
|
Loading…
Reference in a new issue