From 443998f3840ff70e79b86782fbb2be2f50ba4462 Mon Sep 17 00:00:00 2001 From: lowzj Date: Thu, 31 May 2018 07:55:50 +0800 Subject: [PATCH] fix: change timeout from 5m to 10s when file length is 0 --- src/getter/dfget | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/getter/dfget b/src/getter/dfget index 5cdfcc196..ad0c36e9c 100644 --- a/src/getter/dfget +++ b/src/getter/dfget @@ -68,7 +68,7 @@ def download(params): timeout = 5 * 60 if not paramparser.cmdparam.timeout: - if env.file_length > 0: + if env.file_length >= 0: timeout = env.file_length / (64 * 1024) + 10.0 else: timeout = paramparser.cmdparam.timeout