mirror of https://github.com/aria2/aria2
pull/1/head
parent
fc2307d47c
commit
9c67466cde
|
@ -170,7 +170,7 @@ void PeerInteractionCommand::checkLongTimePeerChoking() {
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if(peer->amInterested && peer->peerChoking) {
|
if(peer->amInterested && peer->peerChoking) {
|
||||||
if(Util::difftv(now, chokeCheckPoint) >= 3*60*1000000) {
|
if(Util::difftv(now, chokeCheckPoint) >= MAX_PEER_CHOKING_INTERVAL*1000000) {
|
||||||
throw new DlAbortEx("too long choking");
|
throw new DlAbortEx("too long choking");
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -28,6 +28,8 @@
|
||||||
|
|
||||||
using namespace std;
|
using namespace std;
|
||||||
|
|
||||||
|
#define MAX_PEER_CHOKING_INTERVAL (3*60)
|
||||||
|
|
||||||
class PeerInteractionCommand : public PeerAbstractCommand {
|
class PeerInteractionCommand : public PeerAbstractCommand {
|
||||||
private:
|
private:
|
||||||
int sequence;
|
int sequence;
|
||||||
|
|
Loading…
Reference in New Issue