mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-07-16 02:03:07 -07:00
Allow disabling of OS cache. This will prevent RAM increases on Windows when seeding many files. Closes #1699.
This commit is contained in:
parent
7763a6d2d5
commit
80d6a5a73e
4 changed files with 20 additions and 2 deletions
|
@ -411,6 +411,9 @@ void QBtSession::configureSession() {
|
|||
sessionSettings.cache_size = cache_size ? cache_size * 64 : -1;
|
||||
sessionSettings.cache_expiry = pref->diskCacheTTL();
|
||||
qDebug() << "Using a disk cache size of" << cache_size << "MiB";
|
||||
session_settings::io_buffer_mode_t mode = pref->osCache() ? session_settings::enable_os_cache : session_settings::disable_os_cache;
|
||||
sessionSettings.disk_io_read_mode = mode;
|
||||
sessionSettings.disk_io_write_mode = mode;
|
||||
sessionSettings.anonymous_mode = pref->isAnonymousModeEnabled();
|
||||
if (sessionSettings.anonymous_mode) {
|
||||
addConsoleMessage(tr("Anonymous mode [ON]"), "blue");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue