diff options
| author | Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com> | 2009-01-24 10:40:42 +0000 |
|---|---|---|
| committer | Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com> | 2009-01-24 10:40:42 +0000 |
| commit | adf91f656b3f99ab3a624418b170b9183bfe8d8c (patch) | |
| tree | 40d14bb702aaaf1f8f253b1f2759d9a0c7ed8d89 /src/DownloadEngineFactory.cc | |
| parent | 5da58fe01d31fe2ab647764308dbdb5d93cd721e (diff) | |
2009-01-24 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
Made (piece) hash check sequential for each RequestGroup because
simultaneous hash check is slower than sequential execution.
* src/CheckIntegrityCommand.cc
* src/CheckIntegrityDispatcherCommand.cc
* src/CheckIntegrityDispatcherCommand.h
* src/CheckIntegrityMan.h
* src/ConsoleStatCalc.cc
* src/DownloadCommand.cc
* src/DownloadEngine.cc
* src/DownloadEngine.h
* src/DownloadEngineFactory.cc
* src/Makefile.am
* src/Makefile.in
* src/RequestGroup.cc
* src/StatCalc.h
Diffstat (limited to 'src/DownloadEngineFactory.cc')
| -rw-r--r-- | src/DownloadEngineFactory.cc | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/DownloadEngineFactory.cc b/src/DownloadEngineFactory.cc index 206e9e06..04c15fc3 100644 --- a/src/DownloadEngineFactory.cc +++ b/src/DownloadEngineFactory.cc @@ -45,6 +45,8 @@ #include "FileAllocationMan.h" #ifdef ENABLE_MESSAGE_DIGEST # include "CheckIntegrityMan.h" +# include "CheckIntegrityEntry.h" +# include "CheckIntegrityDispatcherCommand.h" #endif // ENABLE_MESSAGE_DIGEST #include "prefs.h" #include "FillRequestGroupCommand.h" @@ -118,6 +120,11 @@ DownloadEngineFactory::newDownloadEngine(Option* op, e->addRoutineCommand(new FillRequestGroupCommand(e->newCUID(), e.get(), 1)); e->addRoutineCommand(new FileAllocationDispatcherCommand (e->newCUID(), e->_fileAllocationMan, e.get())); +#ifdef ENABLE_MESSAGE_DIGEST + e->addRoutineCommand(new CheckIntegrityDispatcherCommand + (e->newCUID(), e->_checkIntegrityMan, e.get())); +#endif // ENABLE_MESSAGE_DIGEST + if(op->getAsInt(PREF_AUTO_SAVE_INTERVAL) > 0) { e->addRoutineCommand (new AutoSaveCommand(e->newCUID(), e.get(), |
