Ver código fonte

Set DownloadEngine::setNoWait(true) in SleepCommand.

Tatsuhiro Tsujikawa 14 anos atrás
pai
commit
11d7e4fa46
1 arquivos alterados com 3 adições e 1 exclusões
  1. 3 1
      src/SleepCommand.cc

+ 3 - 1
src/SleepCommand.cc

@@ -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);