mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-20 06:50:40 -04:00
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:
parent
b7ace087e6
commit
76d5072624
13 changed files with 100 additions and 42 deletions
|
@ -476,7 +476,13 @@ int pqipersongrp::connectPeer(std::string id)
|
|||
return 1;
|
||||
}
|
||||
|
||||
bool pqipersongrp::notifyConnect(std::string id, uint32_t ptype, bool success)
|
||||
bool pqipersongrp::notifyConnect(std::string id, uint32_t ptype, bool success) {
|
||||
struct sockaddr_in remote_peer_address;
|
||||
sockaddr_clear(&remote_peer_address);
|
||||
notifyConnect(id, ptype, success, remote_peer_address);
|
||||
}
|
||||
|
||||
bool pqipersongrp::notifyConnect(std::string id, uint32_t ptype, bool success, struct sockaddr_in remote_peer_address)
|
||||
{
|
||||
uint32_t type = 0;
|
||||
if (ptype == PQI_CONNECT_TCP)
|
||||
|
@ -496,7 +502,7 @@ bool pqipersongrp::notifyConnect(std::string id, uint32_t ptype, bool success
|
|||
if (ptype == PQI_CONNECT_DO_NEXT_ATTEMPT) {
|
||||
mConnMgr->doNextAttempt(id);
|
||||
} else {
|
||||
mConnMgr->connectResult(id, success, type);
|
||||
mConnMgr->connectResult(id, success, type, remote_peer_address);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue