Re: glibc and getgrouplist
- From: Roland Illig <roland illig gmx de>
- To: Oswald Buddenhagen <ossi kde org>
- Cc: mc-devel gnome org
- Subject: Re: glibc and getgrouplist
- Date: Fri, 22 Jul 2005 20:43:51 +0200
Oswald Buddenhagen wrote:
i'd be opposed to this patch in general if it was not for the plainly
incorrect semantics of the old code.
Why this? It gives us exactly the data we want (the effective and
supplementary group IDs of the current process) instead of something
which is only similar to it (the group IDs of the current user ID).
Additionally, the code is much shorter and simpler.
Third, the code does not use highly dubious int->pointer and
pointer->int casts.
Fourth, it is written with the current SUSv3 standard in mind and agreed
upon by at least three developers. Can you say that of the old code?
Fifth it removes the need to call init_groups() and destroy_groups()
from main.c, which increases modularity.
Sixth, it works even when gid_t or uid_t has a greater width than int.
Any questions left?
Roland
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]