mirror of
https://github.com/d47081/qBittorrent.git
synced 2025-01-22 20:44:15 +00:00
parent
d3e7e8a630
commit
d2a29c2f87
@ -188,10 +188,13 @@ bool SettingsStorage::writeNativeSettings() const
|
||||
break;
|
||||
}
|
||||
|
||||
if (nativeSettings->status() != QSettings::NoError)
|
||||
return false;
|
||||
|
||||
const Path newPath {nativeSettings->fileName()};
|
||||
if (nativeSettings->status() != QSettings::NoError)
|
||||
{
|
||||
Utils::Fs::removeFile(newPath);
|
||||
return false;
|
||||
}
|
||||
|
||||
QString finalPathStr = newPath.data();
|
||||
const int index = finalPathStr.lastIndexOf(u"_new", -1, Qt::CaseInsensitive);
|
||||
finalPathStr.remove(index, 4);
|
||||
|
Loading…
x
Reference in New Issue
Block a user