mirror of
https://github.com/d47081/qBittorrent.git
synced 2025-01-22 20:44:15 +00:00
- Fixed an overflow that could cause ETA to become negative sometimes (hitted an assert)
This commit is contained in:
parent
925ecb3464
commit
3cb34ed7ee
2
TODO
2
TODO
@ -53,7 +53,6 @@
|
||||
* beta 7
|
||||
- update doc for plugins (and add screenies)
|
||||
- update doc for options
|
||||
- See bug about negative ETA
|
||||
- Translations update (IN PROGRESS)
|
||||
- Wait that http://pastebin.ca/690649 is fixed
|
||||
|
||||
@ -114,6 +113,7 @@ beta6->beta7 changelog:
|
||||
- BUGFIX: improved search engine plugin manager code and fixed bugs
|
||||
- BUGFIX: Dropped Qt4.2 support, becomes too difficult to maintain
|
||||
- BUGFIX: Fixed deprecation warning with latest libtorrent svn
|
||||
- BUGFIX: Fixed an overflow causing ETA to become negative sometimes (hitted an assert)
|
||||
- COSMETIC: Improved some icons
|
||||
- COSMETIC: Totally redesigned program preferences
|
||||
- COSMETIC: Improved systray tooltip style
|
||||
|
@ -160,13 +160,14 @@ void bittorrent::updateETAs() {
|
||||
unsigned int nbETAs = listEtas.size();
|
||||
Q_ASSERT(nbETAs);
|
||||
foreach(val, listEtas) {
|
||||
// TODO: Remove this debug when #137223 is fixed
|
||||
qDebug("old moy: %ld", (long)moy);
|
||||
moy += (qlonglong)((double)val/(double)nbETAs);
|
||||
qDebug("ETA: %ld, nbETAs: %d, moy: %ld", (long)val, nbETAs, (long)moy);
|
||||
Q_ASSERT(moy >= 0);
|
||||
if(moy < 0) break;
|
||||
}
|
||||
if(moy < 0) {
|
||||
ETAs.remove(hash);
|
||||
} else {
|
||||
ETAs[hash] = moy;
|
||||
}
|
||||
ETAs[hash] = moy;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user