mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2024-11-27 19:57:45 +03:00
Optimization in tracker list code
This commit is contained in:
parent
c12ae58868
commit
b3d8f2400f
1 changed files with 2 additions and 4 deletions
|
@ -231,10 +231,8 @@ void TrackerList::loadTrackers() {
|
|||
// Load actual trackers information
|
||||
QHash<QString, TrackerInfos> trackers_data = properties->getBTSession()->getTrackersInfo(h.hash());
|
||||
QStringList old_trackers_urls = tracker_items.keys();
|
||||
std::vector<announce_entry> trackers = h.trackers();
|
||||
std::vector<announce_entry>::iterator it;
|
||||
for(it = trackers.begin(); it != trackers.end(); it++) {
|
||||
QStringList item_list;
|
||||
const std::vector<announce_entry> &trackers = h.trackers();
|
||||
for(std::vector<announce_entry>::const_iterator it = trackers.begin(); it != trackers.end(); it++) {
|
||||
QString tracker_url = misc::toQString(it->url);
|
||||
QTreeWidgetItem *item = tracker_items.value(tracker_url, 0);
|
||||
if(!item) {
|
||||
|
|
Loading…
Reference in a new issue