fixed default chunk strategy value (uninitialized)

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@3778 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
csoler 2010-11-11 19:36:39 +00:00
parent c00e11ed2b
commit 9397491634
2 changed files with 4 additions and 3 deletions

View File

@ -121,8 +121,8 @@ class ChunkMap
/// Decides how chunks are selected. /// Decides how chunks are selected.
/// STREAMING: the 1st chunk is always returned /// STREAMING: the 1st chunk is always returned
/// RANDOM: the beginning of a random interval is selected first. If two few intervals /// RANDOM: a uniformly random chunk is selected among available chunks for the current source.
/// exist, the largest one is randomly split into two. ///
void setStrategy(FileChunksInfo::ChunkStrategy s) { _strategy = s ; } void setStrategy(FileChunksInfo::ChunkStrategy s) { _strategy = s ; }
FileChunksInfo::ChunkStrategy getStrategy() const { return _strategy ; } FileChunksInfo::ChunkStrategy getStrategy() const { return _strategy ; }

View File

@ -98,7 +98,8 @@ ftController::ftController(CacheStrapper *cs, ftDataMultiplex *dm, std::string c
mDataplex(dm), mDataplex(dm),
mTurtle(NULL), mTurtle(NULL),
mFtActive(false), mFtActive(false),
mShareDownloadDir(true) mShareDownloadDir(true),
mDefaultChunkStrategy(FileChunksInfo::CHUNK_STRATEGY_RANDOM)
{ {
_max_active_downloads = 5 ; // default queue size _max_active_downloads = 5 ; // default queue size
/* TODO */ /* TODO */