Browse Source

Fix "Seed until ratio reaches x.x" feature

adaptive-webui-19844
Christophe Dumez 15 years ago
parent
commit
78b96accda
  1. 4
      src/bittorrent.cpp

4
src/bittorrent.cpp

@ -203,7 +203,7 @@ bool Bittorrent::isPexEnabled() const { @@ -203,7 +203,7 @@ bool Bittorrent::isPexEnabled() const {
}
void Bittorrent::processBigRatios() {
if(ratio_limit <= 0) return;
if(ratio_limit < 0) return;
qDebug("Process big ratios...");
std::vector<torrent_handle> torrents = s->get_torrents();
std::vector<torrent_handle>::iterator torrentIT;
@ -1838,7 +1838,7 @@ void Bittorrent::addConsoleMessage(QString msg, QString) { @@ -1838,7 +1838,7 @@ void Bittorrent::addConsoleMessage(QString msg, QString) {
// Torrents will a ratio superior to the given value will
// be automatically deleted
void Bittorrent::setMaxRatio(float ratio) {
if(ratio <= 0) ratio = -1.;
if(ratio < 0) ratio = -1.;
if(ratio_limit == -1 && ratio != -1) {
Q_ASSERT(!BigRatioTimer);
BigRatioTimer = new QTimer(this);

Loading…
Cancel
Save