mirror of
https://github.com/trapexit/mergerfs.git
synced 2025-02-27 18:54:11 +08:00
policy_cache.hpp
This commit is contained in:
parent
6c87eee7da
commit
13591eb633
@ -43,7 +43,7 @@ public:
|
||||
insert(std::string const &key_,
|
||||
std::string &val_)
|
||||
{
|
||||
if(_cache.size() > _max_size)
|
||||
if(_cache.size() >= _max_size)
|
||||
_cache.erase(_cache.begin());
|
||||
return &_cache.insert({key_,val_}).first->second;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user