[PATCH] cyrus-imapd: use getgrouplist instead of set/getgrent on systems supporting it
Tomas Janousek
tjanouse at redhat.com
Mon Sep 17 13:07:35 EDT 2007
Hi,
On Mon, Sep 17, 2007 at 10:15:25AM -0400, Ken Murchison wrote:
> Can you explain the use of:
>
> if (pwd || groupids[ngroups] != gid)
Yes. It's linked to the line which reads:
> gid = pwd ? pwd->pw_gid : (gid_t) -1;
If pwd is non-NULL, we supply the gid and expect (and want) it to appear in
the list. If not, we expect -1 to appear in the list a we filter it out.
--
Tomas Janousek, SW Engineer, Red Hat, Inc.
More information about the Cyrus-devel
mailing list