summaryrefslogtreecommitdiffstats
path: root/libktorrent/torrent/singlefilecache.cpp
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-12-18 18:13:41 -0600
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-12-18 18:13:41 -0600
commita90eb215f53c95d81f95b32255098066d90556d9 (patch)
tree333389b0dad6c75eb0f6b5649ec9adcabb18c268 /libktorrent/torrent/singlefilecache.cpp
parent42a9872891eba166e81cf4f8c062261cc77398f8 (diff)
downloadktorrent-a90eb215f53c95d81f95b32255098066d90556d9.tar.gz
ktorrent-a90eb215f53c95d81f95b32255098066d90556d9.zip
Rename old tq methods that no longer need a unique name
Diffstat (limited to 'libktorrent/torrent/singlefilecache.cpp')
-rw-r--r--libktorrent/torrent/singlefilecache.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/libktorrent/torrent/singlefilecache.cpp b/libktorrent/torrent/singlefilecache.cpp
index 4843c1f..8986f98 100644
--- a/libktorrent/torrent/singlefilecache.cpp
+++ b/libktorrent/torrent/singlefilecache.cpp
@@ -76,7 +76,7 @@ namespace bt
{
// mmap continuously fails, so stop using it
c->allocate();
- c->settqStatus(Chunk::BUFFERED);
+ c->setStatus(Chunk::BUFFERED);
}
else
{
@@ -88,7 +88,7 @@ namespace bt
// buffer it if mmapping fails
Out(SYS_GEN|LOG_IMPORTANT) << "Warning : mmap failure, falling back to buffered mode" << endl;
c->allocate();
- c->settqStatus(Chunk::BUFFERED);
+ c->setStatus(Chunk::BUFFERED);
}
else
{
@@ -105,7 +105,7 @@ namespace bt
if (mmap_failures >= 3 || !(buf = (Uint8*)fd->map(c,off,c->getSize(),CacheFile::READ)))
{
c->allocate();
- c->settqStatus(Chunk::BUFFERED);
+ c->setStatus(Chunk::BUFFERED);
fd->read(c->getData(),c->getSize(),off);
if (mmap_failures < 3)
mmap_failures++;
@@ -119,18 +119,18 @@ namespace bt
void SingleFileCache::save(Chunk* c)
{
// unmap the chunk if it is mapped
- if (c->gettqStatus() == Chunk::MMAPPED)
+ if (c->getStatus() == Chunk::MMAPPED)
{
fd->unmap(c->getData(),c->getSize());
c->clear();
- c->settqStatus(Chunk::ON_DISK);
+ c->setStatus(Chunk::ON_DISK);
}
- else if (c->gettqStatus() == Chunk::BUFFERED)
+ else if (c->getStatus() == Chunk::BUFFERED)
{
Uint64 off = c->getIndex() * tor.getChunkSize();
fd->write(c->getData(),c->getSize(),off);
c->clear();
- c->settqStatus(Chunk::ON_DISK);
+ c->setStatus(Chunk::ON_DISK);
}
}