config: rework global config, remove rwlock, make branches RCU like

Also added unit tests. Should have done separately but found a number of bugs.
This commit is contained in:
Antonio SJ Musumeci 2020-12-19 15:06:08 -05:00
parent 2e4c6c5fd1
commit 538467b86d
327 changed files with 6691 additions and 3036 deletions

View file

@ -43,12 +43,13 @@
using std::string;
using std::vector;
namespace l
{
static
int
movefile(Policy::Func::Create createFunc_,
const Branches &branches_,
movefile(const Policy::Create &createFunc_,
const Branches::CPtr &branches_,
const string &fusepath_,
int *origfd_)
{
@ -132,19 +133,19 @@ namespace l
namespace fs
{
int
movefile(const Policy *policy_,
const Branches &basepaths_,
const string &fusepath_,
int *origfd_)
movefile(const Policy::Create &policy_,
const Branches::CPtr &basepaths_,
const string &fusepath_,
int *origfd_)
{
return l::movefile(policy_,basepaths_,fusepath_,origfd_);
}
int
movefile_as_root(const Policy *policy_,
const Branches &basepaths_,
const string &fusepath_,
int *origfd_)
movefile_as_root(const Policy::Create &policy_,
const Branches::CPtr &basepaths_,
const string &fusepath_,
int *origfd_)
{
const ugid::Set ugid(0,0);