mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2025-12-31 20:58:07 -06:00
Merge pull request #6252 from evsh/fix-6248
Do not remove added files unconditionally. Closes #6248
This commit is contained in:
@@ -1576,8 +1576,10 @@ bool Session::addTorrent(QString source, const AddTorrentParams ¶ms)
|
||||
}
|
||||
else {
|
||||
TorrentFileGuard guard(source);
|
||||
guard.markAsAddedToSession();
|
||||
return addTorrent_impl(params, MagnetUri(), TorrentInfo::loadFromFile(source));
|
||||
if (addTorrent_impl(params, MagnetUri(), TorrentInfo::loadFromFile(source))) {
|
||||
guard.markAsAddedToSession();
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user