From dc6a56afcbda039205d62fc6de403776711262b2 Mon Sep 17 00:00:00 2001 From: FranciscoPombal Date: Fri, 21 Feb 2020 13:25:19 +0000 Subject: [PATCH] Revert using random port by default Revert change introduced in https://github.com/qbittorrent/qBittorrent/pull/11637 and also revert the associated follow-up https://github.com/qbittorrent/qBittorrent/pull/12000. Reason: https://github.com/arvidn/libtorrent/pull/4335 --- src/app/upgrade.cpp | 3 +-- src/base/bittorrent/session.cpp | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/app/upgrade.cpp b/src/app/upgrade.cpp index 9d6fb1247..e0a1060cc 100644 --- a/src/app/upgrade.cpp +++ b/src/app/upgrade.cpp @@ -93,8 +93,7 @@ void handleChangedDefaults(const DefaultPreferencesMode mode) }; const QVector changedDefaults { - {QLatin1String {"BitTorrent/Session/QueueingSystemEnabled"}, true, false}, - {QLatin1String {"BitTorrent/Session/UseRandomPort"}, false, true} + {QLatin1String {"BitTorrent/Session/QueueingSystemEnabled"}, true, false} }; SettingsStorage *settingsStorage {SettingsStorage::instance()}; diff --git a/src/base/bittorrent/session.cpp b/src/base/bittorrent/session.cpp index f1db4eb92..da4dda60f 100644 --- a/src/base/bittorrent/session.cpp +++ b/src/base/bittorrent/session.cpp @@ -436,7 +436,7 @@ Session::Session(QObject *parent) , m_isBandwidthSchedulerEnabled(BITTORRENT_SESSION_KEY("BandwidthSchedulerEnabled"), false) , m_saveResumeDataInterval(BITTORRENT_SESSION_KEY("SaveResumeDataInterval"), 60) , m_port(BITTORRENT_SESSION_KEY("Port"), -1) - , m_useRandomPort(BITTORRENT_SESSION_KEY("UseRandomPort"), true) + , m_useRandomPort(BITTORRENT_SESSION_KEY("UseRandomPort"), false) , m_networkInterface(BITTORRENT_SESSION_KEY("Interface")) , m_networkInterfaceName(BITTORRENT_SESSION_KEY("InterfaceName")) , m_networkInterfaceAddress(BITTORRENT_SESSION_KEY("InterfaceAddress"))