mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-14 20:12:29 -04:00
- removed _sharing_strategy and the methods that go with it, as its behavior is handled by the sessionEnabled() method
- added generic tunnel data item, along with item priority consts. Serialization still missing. - added new class for turtle client services, and entry point methods. - removed file name and file size ffrom _outgoing_file_hashes and _incoming_file_hashes. They are not needed. - changed some names to more generic ones. git-svn-id: http://svn.code.sf.net/p/retroshare/code/branches/v0.5-GenericTunneling@6285 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
3bf08d809b
commit
270abcdc94
10 changed files with 349 additions and 272 deletions
|
@ -644,7 +644,7 @@ void ftController::locked_checkQueueElement(uint32_t pos)
|
|||
_queue[pos]->mState = ftFileControl::DOWNLOADING ;
|
||||
|
||||
if(_queue[pos]->mFlags & RS_FILE_REQ_ANONYMOUS_ROUTING)
|
||||
mTurtle->monitorFileTunnels(_queue[pos]->mName,_queue[pos]->mHash,_queue[pos]->mSize) ;
|
||||
mTurtle->monitorTunnels(_queue[pos]->mHash) ;
|
||||
}
|
||||
|
||||
if(pos >= _max_active_downloads && _queue[pos]->mState != ftFileControl::QUEUED && _queue[pos]->mState != ftFileControl::PAUSED)
|
||||
|
@ -653,7 +653,7 @@ void ftController::locked_checkQueueElement(uint32_t pos)
|
|||
_queue[pos]->mCreator->closeFile() ;
|
||||
|
||||
if(_queue[pos]->mFlags & RS_FILE_REQ_ANONYMOUS_ROUTING)
|
||||
mTurtle->stopMonitoringFileTunnels(_queue[pos]->mHash) ;
|
||||
mTurtle->stopMonitoringTunnels(_queue[pos]->mHash) ;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -897,7 +897,7 @@ bool ftController::completeFile(std::string hash)
|
|||
mDownloads.erase(it);
|
||||
|
||||
if(flags & RS_FILE_REQ_ANONYMOUS_ROUTING)
|
||||
mTurtle->stopMonitoringFileTunnels(hash_to_suppress) ;
|
||||
mTurtle->stopMonitoringTunnels(hash_to_suppress) ;
|
||||
|
||||
} /******* UNLOCKED ********/
|
||||
|
||||
|
@ -1262,7 +1262,7 @@ bool ftController::FileRequest(const std::string& fname, const std::string& has
|
|||
// We check that flags are consistent.
|
||||
|
||||
if(flags & RS_FILE_REQ_ANONYMOUS_ROUTING)
|
||||
mTurtle->monitorFileTunnels(fname,hash,size) ;
|
||||
mTurtle->monitorTunnels(hash) ;
|
||||
|
||||
bool assume_availability = flags & RS_FILE_REQ_CACHE ; // assume availability for cache files
|
||||
|
||||
|
@ -1363,7 +1363,7 @@ bool ftController::setChunkStrategy(const std::string& hash,FileChunksInfo::Chun
|
|||
|
||||
bool ftController::FileCancel(const std::string& hash)
|
||||
{
|
||||
rsTurtle->stopMonitoringFileTunnels(hash) ;
|
||||
rsTurtle->stopMonitoringTunnels(hash) ;
|
||||
|
||||
#ifdef CONTROL_DEBUG
|
||||
std::cerr << "ftController::FileCancel" << std::endl;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue