Created
November 1, 2017 05:27
-
-
Save nicolov/9c3e596aad6a5ac597cfb73fe95c6657 to your computer and use it in GitHub Desktop.
aria2 patches
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/src/DownloadCommand.cc b/src/DownloadCommand.cc | |
index 91042ef1..f777dec0 100644 | |
--- a/src/DownloadCommand.cc | |
+++ b/src/DownloadCommand.cc | |
@@ -306,7 +306,7 @@ void DownloadCommand::checkLowestDownloadSpeed() const | |
startupIdleTime_) { | |
int nowSpeed = peerStat_->calculateDownloadSpeed(); | |
if (nowSpeed <= lowestDownloadSpeedLimit_) { | |
- throw DL_ABORT_EX2(fmt(EX_TOO_SLOW_DOWNLOAD_SPEED, nowSpeed, | |
+ throw DL_RETRY_EX2(fmt(EX_TOO_SLOW_DOWNLOAD_SPEED, nowSpeed, | |
lowestDownloadSpeedLimit_, | |
getRequest()->getHost().c_str()), | |
error_code::TOO_SLOW_DOWNLOAD_SPEED); | |
diff --git a/src/HttpSkipResponseCommand.cc b/src/HttpSkipResponseCommand.cc | |
index 14bd37d4..a722d774 100644 | |
--- a/src/HttpSkipResponseCommand.cc | |
+++ b/src/HttpSkipResponseCommand.cc | |
@@ -220,6 +220,7 @@ bool HttpSkipResponseCommand::processResponse() | |
} | |
throw DL_RETRY_EX2(MSG_RESOURCE_NOT_FOUND, | |
error_code::RESOURCE_NOT_FOUND); | |
+ case 502: | |
case 503: | |
// Only retry if pretry-wait > 0. Hammering 'busy' server is not | |
// a good idea. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment