mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-07-30 03:28:41 -07:00
- Fixed remembering of paused torrents cleanly
This commit is contained in:
parent
71e3061c18
commit
cd260198f9
3 changed files with 5 additions and 9 deletions
|
@ -315,12 +315,12 @@ void QTorrentHandle::set_upload_limit(int limit) {
|
|||
h.set_upload_limit(limit);
|
||||
}
|
||||
|
||||
void QTorrentHandle::pause(bool create_file) {
|
||||
void QTorrentHandle::pause() {
|
||||
Q_ASSERT(h.is_valid());
|
||||
h.auto_managed(false);
|
||||
h.pause();
|
||||
// Create .paused file if necessary
|
||||
if(create_file && !QFile::exists(misc::qBittorrentPath()+"BT_backup"+QDir::separator()+hash()+".paused")) {
|
||||
if(!QFile::exists(misc::qBittorrentPath()+"BT_backup"+QDir::separator()+hash()+".paused")) {
|
||||
QFile paused_file(misc::qBittorrentPath()+"BT_backup"+QDir::separator()+hash()+".paused");
|
||||
paused_file.open(QIODevice::WriteOnly | QIODevice::Text);
|
||||
paused_file.close();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue