refs #600, turned CUrlList into a plain vanilla list

* bundled all load balancing in CFailoverUrlList. "Obtain" functions are non-const, no need of mutable members
This commit is contained in:
Klaus Basan
2016-03-13 00:40:11 +00:00
committed by Mathew Sutcliffe
parent 89d9b3ad39
commit 1a1e4681fe
5 changed files with 56 additions and 77 deletions

View File

@@ -161,7 +161,7 @@ namespace BlackCore
// round robin for load balancing
// remark: Don't use QThread to run network operations in the background
// see http://qt-project.org/doc/qt-4.7/qnetworkaccessmanager.html
QUrl url(m_setup.get().vatsimDataFileUrls().getNextUrl());
QUrl url(m_setup.get().vatsimDataFileUrls().getRandomUrl());
if (url.isEmpty()) { return; }
Q_ASSERT_X(this->m_networkManager, Q_FUNC_INFO, "Missing network manager");
QNetworkRequest request(url);