File tree Expand file tree Collapse file tree 5 files changed +5
-5
lines changed Expand file tree Collapse file tree 5 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -996,7 +996,7 @@ int Application::exec()
996996#endif // DISABLE_WEBUI
997997
998998 m_isProcessingParamsAllowed = true ;
999- for (const QBtCommandLineParameters ¶ms : m_paramsQueue)
999+ for (const QBtCommandLineParameters ¶ms : asConst ( m_paramsQueue) )
10001000 processParams (params);
10011001 m_paramsQueue.clear ();
10021002 });
Original file line number Diff line number Diff line change @@ -176,7 +176,7 @@ void GUIAddTorrentManager::onMetadataDownloaded(const BitTorrent::TorrentInfo &m
176176 if (!metadata.isValid ()) [[unlikely]]
177177 return ;
178178
179- for (const auto &[infoHash, dialog] : m_dialogs.asKeyValueRange ())
179+ for (const auto &[infoHash, dialog] : asConst ( m_dialogs) .asKeyValueRange ())
180180 {
181181 if (metadata.matchesInfoHash (infoHash))
182182 dialog->updateMetadata (metadata);
Original file line number Diff line number Diff line change @@ -741,7 +741,7 @@ void TrackerListModel::onTrackersChanged()
741741 trackerItemIDs.insert (m_items->at (i)->name );
742742
743743 QList<std::shared_ptr<Item>> newTrackerItems;
744- for (const BitTorrent::TrackerEntryStatus &trackerEntryStatus : m_torrent->trackers ())
744+ for (const BitTorrent::TrackerEntryStatus &trackerEntryStatus : asConst ( m_torrent->trackers () ))
745745 {
746746 trackerItemIDs.insert (trackerEntryStatus.url );
747747
Original file line number Diff line number Diff line change @@ -630,7 +630,7 @@ void TrackersFilterWidget::handleTorrentsLoaded(const QList<BitTorrent::Torrent
630630 torrentsPerTracker[NULL_HOST].append (torrentID);
631631 }
632632
633- for (const auto &[trackerURL, torrents] : torrentsPerTracker.asKeyValueRange ())
633+ for (const auto &[trackerURL, torrents] : asConst ( torrentsPerTracker) .asKeyValueRange ())
634634 {
635635 addItems (trackerURL, torrents);
636636 }
Original file line number Diff line number Diff line change @@ -609,7 +609,7 @@ void SyncController::makeMaindataSnapshot()
609609 for (const Tag &tag : asConst (session->tags ()))
610610 m_maindataSnapshot.tags .append (tag.toString ());
611611
612- for (const auto &[tracker, torrentIDs] : m_knownTrackers.asKeyValueRange ())
612+ for (const auto &[tracker, torrentIDs] : asConst ( m_knownTrackers) .asKeyValueRange ())
613613 m_maindataSnapshot.trackers [tracker] = asStrings (torrentIDs);
614614
615615 m_maindataSnapshot.serverState = getTransferInfo ();
You can’t perform that action at this time.
0 commit comments