mirror of
https://github.com/trapexit/mergerfs.git
synced 2026-11-29 11:26:44 -05:00
Make allow-idmap optional (default: false) (#1541)
This is just to correct default behavior for now. More investigation is necessary to properly support idmapping.
This commit is contained in:
parent
3cb35a3a65
commit
0f24bb29ac
6 changed files with 27 additions and 4 deletions
|
|
@ -16,6 +16,7 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
#include <assert.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/syscall.h>
|
||||
#include <sys/types.h>
|
||||
|
|
@ -62,6 +63,9 @@ namespace ugid
|
|||
Set(const uid_t newuid_,
|
||||
const gid_t newgid_)
|
||||
{
|
||||
assert((int)newuid_ != -1);
|
||||
assert((int)newgid_ != -1);
|
||||
|
||||
if(!initialized)
|
||||
{
|
||||
currentuid = GETEUID();
|
||||
|
|
@ -81,7 +85,7 @@ namespace ugid
|
|||
if(newgid_)
|
||||
{
|
||||
SETREGID(-1,newgid_);
|
||||
initgroups(newuid_,newgid_);
|
||||
ugid::initgroups(newuid_,newgid_);
|
||||
}
|
||||
|
||||
if(newuid_)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue