small improvements to the chunk checking algorithm

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@5047 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
csoler 2012-03-24 14:45:33 +00:00
parent 0e1b989e08
commit 8f69251334
2 changed files with 43 additions and 37 deletions

View file

@ -151,8 +151,11 @@ void ChunkMap::dataReceived(const ftChunk::ChunkId& cid)
#ifdef DEBUG_FTCHUNK
std::cerr << "*** ChunkMap::dataReceived: Chunk is complete. Removing it." << std::endl ;
#endif
_map[n] = FileChunksInfo::CHUNK_CHECKING ;
_chunks_checking_queue.push_back(n) ;
if(n > 0 || _file_size > CHUNKMAP_FIXED_CHUNK_SIZE) // dont' put <1MB files into checking mode. This is useless.
_chunks_checking_queue.push_back(n) ;
_slices_to_download.erase(itc) ;