mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-03-19 05:26:07 -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
@ -167,8 +167,28 @@ RsCertificate::RsCertificate(const RsPeerDetails& Detail, const unsigned char *b
|
||||
hidden_node = false;
|
||||
hidden_node_address = "";
|
||||
|
||||
scan_ip(Detail.localAddr,Detail.localPort,ipv4_internal_ip_and_port) ;
|
||||
scan_ip(Detail.extAddr,Detail.extPort,ipv4_external_ip_and_port) ;
|
||||
try
|
||||
{
|
||||
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) ;
|
||||
}
|
||||
catch(...)
|
||||
{
|
||||
std::cerr << "RsCertificate::Invalid ExternalAddress";
|
||||
std::cerr << std::endl;
|
||||
memset(ipv4_external_ip_and_port,0,6) ;
|
||||
}
|
||||
|
||||
dns_name = Detail.dyndns ;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user