Added consistent display of chunk map

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@1837 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
csoler 2009-11-18 23:02:37 +00:00
parent adbdb51c5d
commit e88d2c1928
7 changed files with 52 additions and 15 deletions

View file

@ -94,6 +94,20 @@ void ftController::setFtSearchNExtra(ftSearch *search, ftExtraList *list)
mExtraList = list;
}
bool ftController::getFileChunksDetails(const std::string& hash,FileChunksInfo& info)
{
RsStackMutex stack(ctrlMutex); /******* LOCKED ********/
std::map<std::string, ftFileControl>::iterator it = mDownloads.find(hash) ;
if(it == mDownloads.end())
return false ;
it->second.mCreator->getChunkMap(info) ;
return true ;
}
void ftController::addFileSource(const std::string& hash,const std::string& peer_id)
{
RsStackMutex stack(ctrlMutex); /******* LOCKED ********/