From 4f59caf3ca8c33adda9fc75d8e9fb97d9e2d80c5 Mon Sep 17 00:00:00 2001 From: sledgehammer999 Date: Wed, 14 Dec 2016 23:21:40 +0200 Subject: [PATCH] Fix share ratio limiting. Broken by commit 259b5e51c49b744. Closes #6039 #6048. --- src/base/bittorrent/session.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/base/bittorrent/session.cpp b/src/base/bittorrent/session.cpp index faf7fffe9..5ba1f70b7 100644 --- a/src/base/bittorrent/session.cpp +++ b/src/base/bittorrent/session.cpp @@ -1292,7 +1292,8 @@ void Session::processBigRatios() qreal globalMaxRatio = this->globalMaxRatio(); foreach (TorrentHandle *const torrent, m_torrents) { if (torrent->isSeed() - && ((torrent->ratioLimit() != TorrentHandle::NO_RATIO_LIMIT) || !torrent->isForced())) { + && (torrent->ratioLimit() != TorrentHandle::NO_RATIO_LIMIT) + && !torrent->isForced()) { const qreal ratio = torrent->realRatio(); qreal ratioLimit = torrent->ratioLimit(); if (ratioLimit == TorrentHandle::USE_GLOBAL_RATIO) {