mirror of
https://github.com/aria2/aria2.git
synced 2025-02-26 08:22:11 +00:00
Apply --retry-wait when retrying after 404
Previously, --retry-wait was not used when retrying after 404 (--max-file-not-found). The retry was done without delay. Also the maximum retry count (--max-retries) was ignored when retrying with 404. This commit makes --retry-wait apply for retrying with 404 as well. It also combines --max-retries and --max-file-not-found. When retrying with 404, it is counted toward retry count.
This commit is contained in:
parent
c54ecdf8e1
commit
029d6897f2
@ -215,7 +215,8 @@ bool HttpSkipResponseCommand::processResponse()
|
||||
throw DL_ABORT_EX2(MSG_RESOURCE_NOT_FOUND,
|
||||
error_code::RESOURCE_NOT_FOUND);
|
||||
}
|
||||
return prepareForRetry(0);
|
||||
throw DL_RETRY_EX2(MSG_RESOURCE_NOT_FOUND,
|
||||
error_code::RESOURCE_NOT_FOUND);
|
||||
} else if(statusCode == 503) {
|
||||
// Only retry if pretry-wait > 0. Hammering 'busy' server is not
|
||||
// a good idea.
|
||||
|
Loading…
Reference in New Issue
Block a user