added openssl doc quote

This commit is contained in:
Aleksandar Fabijanic 2013-04-21 13:42:14 -05:00
parent 0a153046b4
commit 43df537c49

View File

@ -92,9 +92,14 @@ void OpenSSLInitializer::initialize()
int nMutexes = CRYPTO_num_locks();
_mutexes = new Poco::FastMutex[nMutexes];
CRYPTO_set_locking_callback(&OpenSSLInitializer::lock);
// not needed on windows
// (see SF# 1828231: random unhandled exceptions when linking with ssl)
#ifndef POCO_OS_FAMILY_WINDOWS
// Not needed on Windows (see SF #110: random unhandled exceptions when linking with ssl).
// https://sourceforge.net/p/poco/bugs/110/
//
// From http://www.openssl.org/docs/crypto/threads.html :
// "If the application does not register such a callback using CRYPTO_THREADID_set_callback(),
// then a default implementation is used - on Windows and BeOS this uses the system's
// default thread identifying APIs"
CRYPTO_set_id_callback(&OpenSSLInitializer::id);
#endif
CRYPTO_set_dynlock_create_callback(&OpenSSLInitializer::dynlockCreate);
@ -113,8 +118,6 @@ void OpenSSLInitializer::uninitialize()
EVP_cleanup();
ERR_free_strings();
CRYPTO_set_locking_callback(0);
// not needed on windows
// (see SF# 1828231: random unhandled exceptions when linking with ssl)
#ifndef POCO_OS_FAMILY_WINDOWS
CRYPTO_set_id_callback(0);
#endif