Browse Source

Ensure passthrough and keep_cache are mutually exclusive (#1493)

pull/1494/head
trapexit 3 months ago
committed by GitHub
parent
commit
fa851eda3a
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
  1. 2
      libfuse/lib/fuse.cpp
  2. 4
      src/option_parser.cpp

2
libfuse/lib/fuse.cpp

@ -2373,7 +2373,7 @@ fuse_lib_open(fuse_req_t req,
err = f->fs->op.open(path,&ffi);
if(!err)
{
if(ffi.auto_cache)
if(ffi.auto_cache && (ffi.passthrough == false))
open_auto_cache(f,hdr_->nodeid,path,&ffi);
}
}

4
src/option_parser.cpp

@ -262,8 +262,8 @@ _postprocess_passthrough(Config::Write &cfg_)
if(cfg_->cache_files == CacheFiles::ENUM::OFF)
{
SysLog::warning("'cache.files' can not be 'off' when using 'passthrough'."
" Setting 'cache.files=auto-full'");
cfg_->cache_files = CacheFiles::ENUM::AUTO_FULL;
" Setting 'cache.files=full'");
cfg_->cache_files = CacheFiles::ENUM::FULL;
}
if(cfg_->writeback_cache == true)

Loading…
Cancel
Save