merged RC_1_1 into master

This commit is contained in:
arvidn 2018-11-01 09:37:18 +01:00
commit d0e146eb75
4 changed files with 29 additions and 8 deletions

View File

@ -91,6 +91,8 @@
* resume data no longer has timestamps of files
* require C++11 to build libtorrent
* fix tracker announce issue, advertising port 0 in secondary IPv6 announce
* fix missing boost/noncopyable.hpp includes
* fix python binding for torrent_info::creation_date()
1.1.10 release

View File

@ -1046,8 +1046,8 @@ namespace aux {
#endif
#ifdef TORRENT_USE_OPENSSL
bool use_ssl = req.ssl_ctx != nullptr;
req.ssl_ctx = &m_ssl_ctx;
bool const use_ssl = req.ssl_ctx != nullptr;
if (!use_ssl) req.ssl_ctx = &m_ssl_ctx;
#endif
if (req.outgoing_socket)
@ -5415,7 +5415,22 @@ namespace aux {
else
return std::uint16_t(sock->tcp_external_port);
}
#ifdef TORRENT_USE_OPENSSL
for (auto const& s : m_listen_sockets)
{
if (s->ssl == transport::plaintext)
{
if (m_settings.get_int(settings_pack::proxy_type) != settings_pack::none)
return std::uint16_t(s->udp_external_port);
else
return std::uint16_t(s->tcp_external_port);
}
}
return 0;
#else
return std::uint16_t(m_listen_sockets.front()->tcp_external_port);
#endif
}
// TODO: 2 this function should be removed and users need to deal with the

View File

@ -2899,11 +2899,19 @@ bool is_downloading_state(int const st)
req.outgoing_socket = aep.socket;
#ifndef TORRENT_DISABLE_LOGGING
debug_log("==> TRACKER REQUEST \"%s\" event: %s abort: %d fails: %d upd: %d"
debug_log("==> TRACKER REQUEST \"%s\" event: %s abort: %d ssl: %p "
"port: %d ssl-port: %d fails: %d upd: %d"
, req.url.c_str()
, (req.event == tracker_request::stopped ? "stopped"
: req.event == tracker_request::started ? "started" : "")
, m_abort
#ifdef TORRENT_USE_OPENSSL
, static_cast<void*>(req.ssl_ctx)
#else
, static_cast<void*>(nullptr)
#endif
, m_ses.listen_port()
, m_ses.ssl_listen_port()
, aep.fails
, aep.updating);

View File

@ -270,11 +270,7 @@ namespace libtorrent {
, req.listen_port);
#endif
TORRENT_ASSERT(!m_abort || req.event == tracker_request::stopped);
if (m_abort && req.event != tracker_request::stopped)
return;
std::string protocol = req.url.substr(0, req.url.find(':'));
std::string const protocol = req.url.substr(0, req.url.find(':'));
#ifdef TORRENT_USE_OPENSSL
if (protocol == "http" || protocol == "https")