mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-17 05:22:31 -04:00
patch from Henry Morgan to avoid removing peer permission flags when removing locations
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@6309 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
6590167475
commit
c2fcd8bc71
3 changed files with 8 additions and 7 deletions
|
@ -576,7 +576,7 @@ bool p3PeerMgrIMPL::addFriend(const std::string& input_id, const std::string& in
|
|||
}
|
||||
|
||||
|
||||
bool p3PeerMgrIMPL::removeFriend(const std::string &id)
|
||||
bool p3PeerMgrIMPL::removeFriend(const std::string &id, bool removePgpId)
|
||||
{
|
||||
|
||||
#ifdef PEER_DEBUG
|
||||
|
@ -605,7 +605,8 @@ bool p3PeerMgrIMPL::removeFriend(const std::string &id)
|
|||
peerState peer = it->second;
|
||||
|
||||
sslid_toRemove.push_back(it->second.id);
|
||||
pgpid_toRemove.push_back(it->second.gpg_id);
|
||||
if(removePgpId)
|
||||
pgpid_toRemove.push_back(it->second.gpg_id);
|
||||
|
||||
mOthersList[id] = peer;
|
||||
mStatusChanged = true;
|
||||
|
@ -1889,7 +1890,7 @@ bool p3PeerMgrIMPL::removeAllFriendLocations(const std::string &gpgid)
|
|||
std::list<std::string>::iterator it;
|
||||
for(it = sslIds.begin(); it != sslIds.end(); it++)
|
||||
{
|
||||
removeFriend(*it);
|
||||
removeFriend(*it, true);
|
||||
}
|
||||
|
||||
return true;
|
||||
|
@ -1979,7 +1980,7 @@ bool p3PeerMgrIMPL::removeUnusedLocations()
|
|||
|
||||
for(it = toRemove.begin(); it != toRemove.end(); it++)
|
||||
{
|
||||
removeFriend(*it);
|
||||
removeFriend(*it,false);
|
||||
}
|
||||
|
||||
return true;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue