Bugfixes:

* Corrected mLocal -> mExt in ipset.cc
  * Added pqiipset_test
  * added both Ext and Local address to GUI display.
  * p3connmgr: Ip Addresses only updated if we connected (otherwise port is wrong).
  * p3connmgr: update external address when we get it.



git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@3251 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
drbob 2010-07-04 13:19:09 +00:00
parent 518de7b8c8
commit 6f219d4fef
5 changed files with 228 additions and 32 deletions

View file

@ -319,12 +319,19 @@ bool p3Peers::getPeerDetails(std::string id, RsPeerDetails &d)
std::list<pqiIpAddress>::iterator it;
for(it = pcs.ipAddrs.mLocal.mAddrs.begin();
it != pcs.ipAddrs.mLocal.mAddrs.end(); it++)
{
std::ostringstream toto;
toto << ntohs(it->mAddr.sin_port) << " " << (time(NULL) - it->mSeenTime) << " sec";
d.ipAddressList.push_back("L:" + std::string(inet_ntoa(it->mAddr.sin_addr)) + ":" + toto.str());
}
for(it = pcs.ipAddrs.mExt.mAddrs.begin();
it != pcs.ipAddrs.mExt.mAddrs.end(); it++)
{
std::ostringstream toto;
toto << ntohs(it->mAddr.sin_port) << " " << (time(NULL) - it->mSeenTime) << " sec";
d.ipAddressList.push_back(std::string(inet_ntoa(it->mAddr.sin_addr)) + ":" + toto.str());
d.ipAddressList.push_back("E:" + std::string(inet_ntoa(it->mAddr.sin_addr)) + ":" + toto.str());
}