mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-04 07:05:26 -04:00
fixed bad parse of addresses in certificate.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/branches/v0.6-initdev@7032 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
b741503803
commit
8c8baae044
1 changed files with 22 additions and 2 deletions
|
@ -167,8 +167,28 @@ RsCertificate::RsCertificate(const RsPeerDetails& Detail, const unsigned char *b
|
||||||
hidden_node = false;
|
hidden_node = false;
|
||||||
hidden_node_address = "";
|
hidden_node_address = "";
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
scan_ip(Detail.localAddr,Detail.localPort,ipv4_internal_ip_and_port) ;
|
scan_ip(Detail.localAddr,Detail.localPort,ipv4_internal_ip_and_port) ;
|
||||||
|
}
|
||||||
|
catch(...)
|
||||||
|
{
|
||||||
|
std::cerr << "RsCertificate::Invalid LocalAddress";
|
||||||
|
std::cerr << std::endl;
|
||||||
|
memset(ipv4_internal_ip_and_port,0,6) ;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
try
|
||||||
|
{
|
||||||
scan_ip(Detail.extAddr,Detail.extPort,ipv4_external_ip_and_port) ;
|
scan_ip(Detail.extAddr,Detail.extPort,ipv4_external_ip_and_port) ;
|
||||||
|
}
|
||||||
|
catch(...)
|
||||||
|
{
|
||||||
|
std::cerr << "RsCertificate::Invalid ExternalAddress";
|
||||||
|
std::cerr << std::endl;
|
||||||
|
memset(ipv4_external_ip_and_port,0,6) ;
|
||||||
|
}
|
||||||
|
|
||||||
dns_name = Detail.dyndns ;
|
dns_name = Detail.dyndns ;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue