diff options
| author | Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com> | 2009-07-04 13:36:56 +0000 |
|---|---|---|
| committer | Tatsuhiro Tsujikawa <tatsuhiro.t@gmail.com> | 2009-07-04 13:36:56 +0000 |
| commit | a7c222b8ab5a072d5bf47a8de5eda82867ed6a38 (patch) | |
| tree | b92b4f0b57a59f6d7137e57cce348302cea607f0 /src/CreateRequestCommand.cc | |
| parent | 3a655a5d1a968373cd0f58604962d930d7912737 (diff) | |
2009-07-04 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
Made URI reusing function work.
* src/CreateRequestCommand.cc
* src/FileEntry.cc
* src/FileEntry.h
* test/FileEntryTest.cc
Diffstat (limited to 'src/CreateRequestCommand.cc')
| -rw-r--r-- | src/CreateRequestCommand.cc | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/CreateRequestCommand.cc b/src/CreateRequestCommand.cc index adfd625e..311cc8b9 100644 --- a/src/CreateRequestCommand.cc +++ b/src/CreateRequestCommand.cc @@ -67,6 +67,10 @@ bool CreateRequestCommand::executeInternal() _fileEntry = _requestGroup->getDownloadContext()->findFileEntryByOffset (_segments.front()->getPositionToWrite()); } + if(_fileEntry->getRemainingUris().empty() && + getOption()->getAsBool(PREF_REUSE_URI)) { + _fileEntry->reuseUri(_requestGroup->getNumConcurrentCommand()); + } req = _fileEntry->getRequest(_requestGroup->getURISelector(), getOption()->get(PREF_REFERER), // Don't use HEAD request when file |
