mirror of https://github.com/aria2/aria2
2010-03-08 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
Added debug logs. * src/FileEntry.cc * src/SegmentMan.ccpull/1/head
parent
d57ba674c4
commit
2c2d19d5d5
|
@ -1,3 +1,9 @@
|
|||
2010-03-08 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
|
||||
|
||||
Added debug logs.
|
||||
* src/FileEntry.cc
|
||||
* src/SegmentMan.cc
|
||||
|
||||
2010-03-08 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
|
||||
|
||||
Fixed unit test error with mingw32 build.
|
||||
|
|
|
@ -306,6 +306,10 @@ void FileEntry::reuseUri(size_t num)
|
|||
size_t ininum = reusableURIs.size();
|
||||
if(_logger->debug()) {
|
||||
_logger->debug("Found %u reusable URIs", static_cast<unsigned int>(ininum));
|
||||
for(std::vector<std::string>::const_iterator i = reusableURIs.begin(),
|
||||
eoi = reusableURIs.end(); i != eoi; ++i) {
|
||||
_logger->debug("URI=%s", (*i).c_str());
|
||||
}
|
||||
}
|
||||
// Reuse at least num URIs here to avoid to
|
||||
// run this process repeatedly.
|
||||
|
|
|
@ -395,6 +395,12 @@ size_t SegmentMan::countFreePieceFrom(size_t index) const
|
|||
|
||||
void SegmentMan::ignoreSegmentFor(const SharedHandle<FileEntry>& fileEntry)
|
||||
{
|
||||
if(logger->debug()) {
|
||||
logger->debug("ignoring segment for path=%s, offset=%s, length=%s",
|
||||
fileEntry->getPath().c_str(),
|
||||
util::itos(fileEntry->getOffset()).c_str(),
|
||||
util::uitos(fileEntry->getLength()).c_str());
|
||||
}
|
||||
_ignoreBitfield.addFilter(fileEntry->getOffset(), fileEntry->getLength());
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue