fixed stupid mistake in commit 7858 in SSL error handling causing impossibility to connect

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7866 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
csoler 2015-01-23 19:17:33 +00:00
parent 0e3cd003ad
commit 352d8413c0

View File

@ -1099,19 +1099,16 @@ int AuthSSLimpl::VerifyX509Callback(int preverify_ok, X509_STORE_CTX *ctx)
int err, depth;
err_cert = X509_STORE_CTX_get_current_cert(ctx);
#ifdef AUTHSSL_DEBUG
err = X509_STORE_CTX_get_error(ctx);
depth = X509_STORE_CTX_get_error_depth(ctx);
#endif
if(err_cert == NULL)
{
std::cerr << "AuthSSLimpl::VerifyX509Callback(): Cannot get certificate. Error!" << std::endl;
return false ;
}
if(err != X509_V_OK)
{
std::cerr << "AuthSSLimpl::VerifyX509Callback(): get certificate returned error code =" << err << ", error depth=" << depth << std::endl;
return false ;
}
#ifdef AUTHSSL_DEBUG
std::cerr << "AuthSSLimpl::VerifyX509Callback(preverify_ok: " << preverify_ok
<< " Err: " << err << " Depth: " << depth << std::endl;