- Fix per-torrent speed limiting

This commit is contained in:
Christophe Dumez
2009-11-17 13:19:24 +00:00
parent 2b9f0ae94f
commit 96f9add49a
2 changed files with 9 additions and 0 deletions

View File

@@ -4,6 +4,7 @@
- BUGFIX: Fixed memory leak in RSS parser
- BUGFIX: Fixed possible crash in search autocompletion
- BUGFIX: Improved ETA calculation for big torrents
- BUGFIX: Fixed per-torrent speed limiting
* Wed Nov 4 2009 - Christophe Dumez <chris@qbittorrent.org> - v1.5.5
- BUGFIX: Fixed man page

View File

@@ -493,6 +493,10 @@ QTorrentHandle bittorrent::addMagnetUri(QString magnet_uri, bool resumed) {
h.set_max_connections(maxConnecsPerTorrent);
// Uploads limit per torrent
h.set_max_uploads(maxUploadsPerTorrent);
if(TorrentPersistentData::isKnownTorrent(h.hash())) {
h.set_download_limit(TorrentPersistentData::getDownloadLimit(h.hash()));
h.set_upload_limit(TorrentPersistentData::getUploadLimit(h.hash()));
}
// Load filtered files
if(resumed) {
// Load custom url seeds
@@ -657,6 +661,10 @@ QTorrentHandle bittorrent::addTorrent(QString path, bool fromScanDir, QString fr
h.set_max_connections(maxConnecsPerTorrent);
// Uploads limit per torrent
h.set_max_uploads(maxUploadsPerTorrent);
if(TorrentPersistentData::isKnownTorrent(h.hash())) {
h.set_download_limit(TorrentPersistentData::getDownloadLimit(h.hash()));
h.set_upload_limit(TorrentPersistentData::getUploadLimit(h.hash()));
}
// Load filtered files
loadFilesPriorities(h);
if(resumed) {