mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-12-21 21:55:15 -05:00
add a test for connection establishement
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@2048 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
545f37e615
commit
de1f223d7d
@ -2217,10 +2217,10 @@ int AuthSSL::VerifyX509Callback(int preverify_ok, X509_STORE_CTX *ctx)
|
||||
//set location
|
||||
mConnMgr->setLocation(certId, getX509LocString(X509_STORE_CTX_get_current_cert(ctx)->cert_info->subject));
|
||||
|
||||
//Cgheck if peer isn't already connected
|
||||
//Check if peer isn't already connected
|
||||
peerConnectState detail;
|
||||
if (mConnMgr->getFriendNetStatus(certId, detail)) {
|
||||
if (detail.state & RS_PEER_CONNECTED && detail.connecttype & RS_NET_CONN_TUNNEL) {
|
||||
if (detail.state & RS_PEER_CONNECTED && !(detail.connecttype & RS_NET_CONN_TUNNEL)) {
|
||||
fprintf(stderr, "AuthSSL::VerifyX509Callback this peer is already connected, refuse a new connection.");
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user