diff --git a/Changelog b/Changelog index eea393768..c8f700726 100644 --- a/Changelog +++ b/Changelog @@ -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 - v1.5.5 - BUGFIX: Fixed man page diff --git a/src/bittorrent.cpp b/src/bittorrent.cpp index 4df1515d1..1d2b04f6c 100644 --- a/src/bittorrent.cpp +++ b/src/bittorrent.cpp @@ -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) {