core: Provide helper macro to set [ug]id in frame
Signed-off-by: Shehjar Tikoo <shehjart@gluster.com> Signed-off-by: Anand V. Avati <avati@dev.gluster.com> BUG: 400 (Support auxiliary gids in GlusterFS) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=400
This commit is contained in:
parent
efa1ce755b
commit
1582bc4e20
@ -104,6 +104,15 @@ struct _call_stack_t {
|
||||
};
|
||||
|
||||
|
||||
#define frame_set_uid_gid(frm, u, g) \
|
||||
do { \
|
||||
if (frm) { \
|
||||
(frm)->root->uid = u; \
|
||||
(frm)->root->gid = g; \
|
||||
(frm)->root->ngrps = 0; \
|
||||
} \
|
||||
} while (0); \
|
||||
|
||||
static inline void
|
||||
FRAME_DESTROY (call_frame_t *frame)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user