mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2024-11-23 17:56:50 +03:00
Fix compilation errors with libtorrent < 0.15.5
This commit is contained in:
parent
549fcf8b4c
commit
0b9f9aa0d7
1 changed files with 9 additions and 0 deletions
|
@ -65,6 +65,7 @@
|
|||
#include <libtorrent/identify_client.hpp>
|
||||
#include <libtorrent/alert_types.hpp>
|
||||
#include <libtorrent/torrent_info.hpp>
|
||||
#include <libtorrent/version.hpp>
|
||||
#include <boost/filesystem/exception.hpp>
|
||||
#include <queue>
|
||||
|
||||
|
@ -1860,7 +1861,15 @@ void QBtSession::setSessionSettings(const session_settings &sessionSettings) {
|
|||
// Set Proxy
|
||||
void QBtSession::setProxySettings(const proxy_settings &proxySettings) {
|
||||
qDebug() << Q_FUNC_INFO;
|
||||
|
||||
#if (LIBTORRENT_VERSION_MINOR > 15) || (LIBTORRENT_VERSION_MINOR == 15 && LIBTORRENT_VERSION_TINY > 4)
|
||||
s->set_proxy(proxySettings);
|
||||
#else
|
||||
s->set_peer_proxy(proxySettings);
|
||||
s->set_web_seed_proxy(proxySettings);
|
||||
s->set_tracker_proxy(proxySettings);
|
||||
s->set_dht_proxy(proxySettings);
|
||||
#endif
|
||||
// Define environment variable
|
||||
QString proxy_str;
|
||||
switch(proxySettings.type) {
|
||||
|
|
Loading…
Reference in a new issue