fix: gcc 13 warnings, pt. 1 (#6400)

* fix: nullptr dereference warnings

* fix: mixed enumerated and non-enumerated warning

* fix: -Wnull-dereference warning in qt/MainWindow.cc

* fix: -Wnull-dereference warning in TorrentFilter::countTorrentsPerMode()

* fix: -Wnull-dereference warning in VariantHelpers::change(TrackerStat&, tr_variant*)

* build: bump google-test from 1.12.1 to 1.14.0

* Revert "build: bump google-test from 1.12.1 to 1.14.0"

This reverts commit 6fdcffa5de.
This commit is contained in:
Charles Kerr
2023-12-17 12:49:39 -06:00
committed by GitHub
parent 8177c883b0
commit 2dea0b5fa2
8 changed files with 92 additions and 85 deletions

View File

@@ -891,7 +891,11 @@ void MainWindow::refreshActionSensitivity()
auto const now = time(nullptr);
for (auto const& row : selection_model->selectedRows())
{
auto const& tor = model->data(row, TorrentModel::TorrentRole).value<Torrent const*>();
auto const* const tor = model->data(row, TorrentModel::TorrentRole).value<Torrent const*>();
if (tor == nullptr)
{
continue;
}
++selected;