support boost version older than 1.64 by falling back to tlsv12_client (instead of tls_client)

This commit is contained in:
arvidn 2020-04-14 13:26:40 +02:00 committed by Arvid Norberg
parent fdbffda157
commit ce57c2d5af
1 changed files with 5 additions and 0 deletions

View File

@ -454,8 +454,13 @@ namespace aux {
: m_settings(pack)
, m_io_service(ios)
#ifdef TORRENT_USE_OPENSSL
#if BOOST_VERSION >= 106400
, m_ssl_ctx(ssl::context::tls_client)
, m_peer_ssl_ctx(ssl::context::tls)
#else
, m_ssl_ctx(ssl::context::tlsv12_client)
, m_peer_ssl_ctx(ssl::context::tlsv12)
#endif
#endif
, m_alerts(m_settings.get_int(settings_pack::alert_queue_size)
, alert_category_t{static_cast<unsigned int>(m_settings.get_int(settings_pack::alert_mask))})