From 3752d112fb8cdbb40e34bc638d852134796727d5 Mon Sep 17 00:00:00 2001 From: Eugene Shalygin Date: Wed, 8 Mar 2017 09:03:35 +0100 Subject: [PATCH] Fix TorrentFileGuard::setAutoRemove() recursion problem. Closes #6488. The problem was created during Qt 4 drop, when FileGuard was promoted from a member to a base class. The function was blindly changed. --- src/base/torrentfileguard.cpp | 5 ----- src/base/torrentfileguard.h | 2 +- 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/src/base/torrentfileguard.cpp b/src/base/torrentfileguard.cpp index 2fc1306e7..5369ea510 100644 --- a/src/base/torrentfileguard.cpp +++ b/src/base/torrentfileguard.cpp @@ -77,11 +77,6 @@ void TorrentFileGuard::markAsAddedToSession() m_wasAdded = true; } -void TorrentFileGuard::setAutoRemove(bool remove) -{ - setAutoRemove(remove); -} - TorrentFileGuard::AutoDeleteMode TorrentFileGuard::autoDeleteMode() { QMetaEnum meta {modeMetaEnum()}; diff --git a/src/base/torrentfileguard.h b/src/base/torrentfileguard.h index 1c8871764..b89651592 100644 --- a/src/base/torrentfileguard.h +++ b/src/base/torrentfileguard.h @@ -60,7 +60,7 @@ public: /// marks the torrent file as loaded (added) into the BitTorrent::Session void markAsAddedToSession(); - void setAutoRemove(bool remove); + using FileGuard::setAutoRemove; enum AutoDeleteMode // do not change these names: they are stored in config file {