mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2025-12-22 08:27:24 -06:00
Enabling Windows disk cache (and adding option to disable it) to prevent a relatively prevalent ERROR_INVALID_PARAMETER.
From my test only the write cache was the culprit, if this can be confirmed the read cache can be disabled by default if that has a benefit. (Other systems are unchanged.)
This commit is contained in:
@@ -934,6 +934,22 @@ public:
|
||||
setValue(QString::fromUtf8("Preferences/Downloads/DiskCache"), size);
|
||||
}
|
||||
|
||||
bool disableOSWriteCache() const {
|
||||
return value(QString::fromUtf8("Preferences/Advanced/DisableOSWriteCache"), false).toBool();
|
||||
}
|
||||
|
||||
void disableOSWriteCache(bool disable) {
|
||||
setValue(QString::fromUtf8("Preferences/Advanced/DisableOSWriteCache"), disable);
|
||||
}
|
||||
|
||||
bool disableOSReadCache() const {
|
||||
return value(QString::fromUtf8("Preferences/Advanced/DisableOSReadCache"), false).toBool();
|
||||
}
|
||||
|
||||
void disableOSReadCache(bool disable) {
|
||||
setValue(QString::fromUtf8("Preferences/Advanced/DisableOSReadCache"), disable);
|
||||
}
|
||||
|
||||
uint outgoingPortsMin() const {
|
||||
return value(QString::fromUtf8("Preferences/Advanced/OutgoingPortsMin"), 0).toUInt();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user