mirror of
https://github.com/d47081/qBittorrent.git
synced 2025-01-11 15:27:54 +00:00
Fix ETA calculation when some files are downloaded and marked afterwards as 'do not download'.
This commit is contained in:
parent
37f821556e
commit
6bea659d50
@ -404,7 +404,7 @@ bool QTorrentHandle::is_checking() const {
|
|||||||
|
|
||||||
size_type QTorrentHandle::total_done() const {
|
size_type QTorrentHandle::total_done() const {
|
||||||
#if LIBTORRENT_VERSION_NUM >= 001600
|
#if LIBTORRENT_VERSION_NUM >= 001600
|
||||||
return torrent_handle::status(0x0).total_done;
|
return torrent_handle::status(query_accurate_download_counters).total_done;
|
||||||
#else
|
#else
|
||||||
return torrent_handle::status().total_done;
|
return torrent_handle::status().total_done;
|
||||||
#endif
|
#endif
|
||||||
|
@ -150,7 +150,7 @@ qlonglong TorrentSpeedMonitor::getETA(const QString &hash) const
|
|||||||
if (!speed_average.download)
|
if (!speed_average.download)
|
||||||
return MAX_ETA;
|
return MAX_ETA;
|
||||||
|
|
||||||
return (h.total_wanted() - h.total_done()) / speed_average.download;
|
return (h.total_wanted() - h.total_wanted_done()) / speed_average.download;
|
||||||
}
|
}
|
||||||
|
|
||||||
void TorrentSpeedMonitor::getSamples()
|
void TorrentSpeedMonitor::getSamples()
|
||||||
|
Loading…
Reference in New Issue
Block a user