mirror of
https://github.com/transmission/transmission
synced 2024-12-31 20:16:57 +00:00
ensure announcer tracker count is correct
This commit is contained in:
parent
0f92232c65
commit
0cedfec630
4 changed files with 11 additions and 8 deletions
|
@ -1802,6 +1802,14 @@ static tr_tracker_view trackerView(tr_torrent const& tor, int tier_index, tr_tie
|
|||
return view;
|
||||
}
|
||||
|
||||
size_t tr_announcerTrackerCount(tr_torrent const* tor)
|
||||
{
|
||||
TR_ASSERT(tr_isTorrent(tor));
|
||||
TR_ASSERT(tor->tiers != nullptr);
|
||||
|
||||
return tor->tiers->tracker_count;
|
||||
}
|
||||
|
||||
tr_tracker_view tr_announcerTracker(tr_torrent const* tor, size_t nth)
|
||||
{
|
||||
TR_ASSERT(tr_isTorrent(tor));
|
||||
|
|
|
@ -95,6 +95,8 @@ time_t tr_announcerNextManualAnnounce(tr_torrent const*);
|
|||
|
||||
tr_tracker_view tr_announcerTracker(tr_torrent const* torrent, size_t i);
|
||||
|
||||
size_t tr_announcerTrackerCount(tr_torrent const* tor);
|
||||
|
||||
/***
|
||||
****
|
||||
***/
|
||||
|
|
|
@ -1255,7 +1255,7 @@ tr_tracker_view tr_torrentTracker(tr_torrent const* tor, size_t i)
|
|||
|
||||
size_t tr_torrentTrackerCount(tr_torrent const* tor)
|
||||
{
|
||||
return tor->trackerCount();
|
||||
return tr_announcerTrackerCount(tor);
|
||||
}
|
||||
|
||||
/***
|
||||
|
|
|
@ -348,13 +348,6 @@ public:
|
|||
return info.webseeds[i];
|
||||
}
|
||||
|
||||
/// TRACKERS
|
||||
|
||||
auto trackerCount() const
|
||||
{
|
||||
return info.trackerCount;
|
||||
}
|
||||
|
||||
/// CHECKSUMS
|
||||
|
||||
bool ensurePieceIsChecked(tr_piece_index_t piece)
|
||||
|
|
Loading…
Reference in a new issue