diff options
| author | Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com> | 2010-06-08 14:11:36 +0000 |
|---|---|---|
| committer | Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com> | 2010-06-08 14:11:36 +0000 |
| commit | 7cd9b21937c42606354610c7ae85a0857b474cf5 (patch) | |
| tree | 21edec9e14d7bde8cfa705840a6e9756b732e1e5 /src/FileAllocationCommand.cc | |
| parent | 2dc4bf01ad3b9be3de22696128e8007cf81a5345 (diff) | |
2010-06-08 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
Made public member variables of DownloadEngine private. Added
accessor funcs.
Diffstat (limited to 'src/FileAllocationCommand.cc')
| -rw-r--r-- | src/FileAllocationCommand.cc | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/FileAllocationCommand.cc b/src/FileAllocationCommand.cc index 7046e7cf..94c2dd87 100644 --- a/src/FileAllocationCommand.cc +++ b/src/FileAllocationCommand.cc @@ -46,6 +46,9 @@ #include "a2functional.h" #include "RecoverableException.h" #include "wallclock.h" +#include "RequestGroupMan.h" +#include "CheckIntegrityEntry.h" +#include "ServerStatMan.h" namespace aria2 { @@ -60,7 +63,7 @@ FileAllocationCommand::~FileAllocationCommand() {} bool FileAllocationCommand::executeInternal() { if(_requestGroup->isHaltRequested()) { - _e->_fileAllocationMan->dropPickedEntry(); + _e->getFileAllocationMan()->dropPickedEntry(); return true; } _fileAllocationEntry->allocateChunk(); @@ -70,7 +73,7 @@ bool FileAllocationCommand::executeInternal() _timer.difference(global::wallclock), util::itos(_requestGroup->getTotalLength(), true).c_str()); } - _e->_fileAllocationMan->dropPickedEntry(); + _e->getFileAllocationMan()->dropPickedEntry(); std::vector<Command*> commands; try { @@ -83,14 +86,14 @@ bool FileAllocationCommand::executeInternal() _e->setNoWait(true); return true; } else { - _e->commands.push_back(this); + _e->addCommand(this); return false; } } bool FileAllocationCommand::handleException(Exception& e) { - _e->_fileAllocationMan->dropPickedEntry(); + _e->getFileAllocationMan()->dropPickedEntry(); logger->error(MSG_FILE_ALLOCATION_FAILURE, e, util::itos(cuid).c_str()); logger->error(MSG_DOWNLOAD_NOT_COMPLETE, util::itos(cuid).c_str(), _requestGroup->getDownloadContext()->getBasePath().c_str()); |
