From 74c74f8dccc01c99c8098dcb0dcae5cfaa81566d Mon Sep 17 00:00:00 2001 From: James Peach Date: Fri, 8 Jun 2007 22:25:55 +0000 Subject: r23393: Support BSD group semantics by making sure that the effective GID is always passed as the first GID when calling setgroups(2). (This used to be commit 6ebaf856c1d27f2fbfa0444a5c6c17c4331d2780) --- source3/lib/system_smbd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'source3/lib/system_smbd.c') diff --git a/source3/lib/system_smbd.c b/source3/lib/system_smbd.c index 509b2bbcb1..0d62360ca6 100644 --- a/source3/lib/system_smbd.c +++ b/source3/lib/system_smbd.c @@ -104,7 +104,7 @@ static int getgrouplist_internals(const char *user, gid_t gid, gid_t *groups, restore_re_gid(); - if (sys_setgroups(ngrp_saved, gids_saved) != 0) { + if (sys_setgroups(gid, ngrp_saved, gids_saved) != 0) { /* yikes! */ DEBUG(0,("ERROR: getgrouplist: failed to reset group list!\n")); smb_panic("getgrouplist: failed to reset group list!\n"); -- cgit