This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author Alexander.Belopolsky
Recipients Alexander.Belopolsky, l0nwlf, loewis, orsenthil, r.david.murray, ronaldoussoren
Date 2010-02-23.17:47:48
SpamBayes Score 8.1392485e-05
Marked as misclassified No
Message-id <>
On Tue, Feb 23, 2010 at 12:16 PM, Ronald Oussoren <> wrote:
> How did you detect that the modern getgroups implementation doesn't
> query the kernel? That would be very odd.

I wish I could say that I mastered dtrace under OSX, but I am not there yet. :-)  There are two facts that convinced me that this is the case

1. Since setgroups is the same regardless of _DARWIN_C_SOURCE but getgroups returns different values after setgroups in programs compiled with an without _DARWIN_C_SOURCE, the problem must be in getgroups.

2. Setting breakpoint at getpwuid in gdb I see that it is not called when _DARWIN_C_SOURCE is not set, but when it is

(gdb) where
#0  0x00007fff86d2c487 in getpwuid ()
#1  0x00007fff86da229b in getgroups$DARWIN_EXTSN ()
#2  0x0000000100000ddd in printgroups ()
#3  0x0000000100000e6e in main ()
Date User Action Args
2010-02-23 17:47:51Alexander.Belopolskysetrecipients: + Alexander.Belopolsky, loewis, ronaldoussoren, orsenthil, r.david.murray, l0nwlf
2010-02-23 17:47:51Alexander.Belopolskysetmessageid: <>
2010-02-23 17:47:49Alexander.Belopolskylinkissue7900 messages
2010-02-23 17:47:48Alexander.Belopolskycreate