From 051052e9e2a12c9616685eeab109dbc2358c119f Mon Sep 17 00:00:00 2001 From: Tatsuhiro Tsujikawa Date: Sun, 5 Jul 2009 03:08:18 +0000 Subject: [PATCH] 2009-07-05 Tatsuhiro Tsujikawa Removed the call to DiskAdaptor::onDownloadComplete() from BtCheckIntegrityEntry and DefaultPieceStorage. * src/BtCheckIntegrityEntry.cc * src/DefaultPieceStorage.cc --- ChangeLog | 7 +++++++ src/BtCheckIntegrityEntry.cc | 1 - src/DefaultPieceStorage.cc | 1 - 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 7f01b775..939d90f5 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2009-07-05 Tatsuhiro Tsujikawa + + Removed the call to DiskAdaptor::onDownloadComplete() from + BtCheckIntegrityEntry and DefaultPieceStorage. + * src/BtCheckIntegrityEntry.cc + * src/DefaultPieceStorage.cc + 2009-07-05 Tatsuhiro Tsujikawa Commented out throw statements when number of piece is 0 to diff --git a/src/BtCheckIntegrityEntry.cc b/src/BtCheckIntegrityEntry.cc index 8aa1277c..a4f177bc 100644 --- a/src/BtCheckIntegrityEntry.cc +++ b/src/BtCheckIntegrityEntry.cc @@ -68,7 +68,6 @@ void BtCheckIntegrityEntry::onDownloadIncomplete(std::deque& commands, void BtCheckIntegrityEntry::onDownloadFinished(std::deque& commands, DownloadEngine* e) { - _requestGroup->getPieceStorage()->getDiskAdaptor()->onDownloadComplete(); // TODO Currently,when all the checksums // are valid, then aira2 goes to seeding mode. Sometimes it is better // to exit rather than doing seeding. So, it would be good to toggle this diff --git a/src/DefaultPieceStorage.cc b/src/DefaultPieceStorage.cc index 02547bf0..a9edf5ca 100644 --- a/src/DefaultPieceStorage.cc +++ b/src/DefaultPieceStorage.cc @@ -346,7 +346,6 @@ void DefaultPieceStorage::completePiece(const PieceHandle& piece) addPieceStats(piece->getIndex()); if(downloadFinished()) { downloadContext->resetDownloadStopTime(); - diskAdaptor->onDownloadComplete(); if(isSelectiveDownloadingMode()) { logger->notice(MSG_SELECTIVE_DOWNLOAD_COMPLETED); // following line was commented out in order to stop sending request