Set DownloadEngine::setNoWait(true) in SleepCommand.

pull/1/head
Tatsuhiro Tsujikawa 2011-04-30 23:45:17 +09:00
parent 1122e55a35
commit 11d7e4fa46
1 changed files with 3 additions and 1 deletions

View File

@ -52,9 +52,11 @@ SleepCommand::~SleepCommand() {
bool SleepCommand::execute() {
if(requestGroup_->downloadFinished() || requestGroup_->isHaltRequested()) {
return true;
} else if(checkPoint_.difference(global::wallclock) >= wait_) {
} else if(checkPoint_.differenceInMillis(global::wallclock)+A2_DELTA_MILLIS
>= wait_*1000) {
engine_->addCommand(nextCommand_);
nextCommand_ = 0;
engine_->setNoWait(true);
return true;
} else {
engine_->addCommand(this);