add ext address detector when connectiong to peers

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@1882 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
joss17 2009-12-14 18:11:19 +00:00
parent b7ace087e6
commit 76d5072624
13 changed files with 100 additions and 42 deletions

View file

@ -710,6 +710,13 @@ void p3disc::recvPeerFriendMsg(RsDiscReply *item)
mConnMgr->stunStatus(hashid1, item->currentsaddr, type, RS_STUN_FRIEND_OF_FRIEND);
}
/* send Own Ip list to connect manager. It will extract the external ip address from it */
if (peerId == mConnMgr->getOwnId())
{
mConnMgr->setAddressList(mConnMgr->getOwnId(), item->ipAddressList);
}
addDiscoveryData(item->PeerId(), peerId, item->currentladdr, item->currentsaddr, item->discFlags, time(NULL));
rsicontrol->getNotify().notifyListChange(NOTIFY_LIST_NEIGHBOURS, NOTIFY_TYPE_MOD);