From: Eric B. <er...@go...> - 2007-12-15 09:01:53
|
Franck Arnaud wrote: > hi, > > I can't bootstrap the current repository, fails on compiling > eif_group_in_list because my Linux does not have NGROUPS_MAX (or not in > the expected place). I guess it is supposed to be in limits.h. Does it work if you add this include explicitly at the beginning of file $GOBO/tool/gec/runtime/c/eif_file.c? > It seems NGROUPS_MAX was changed to 65000 from 32 between Linux kernel > releases so the hardcoded NGROUPS_MAX technique not very reliable as the > value depend on C library on the compiling machine and real value on > kernel. > > I guess the clean way is to malloc () the structure with the value > returned by getgroups (0, _) which returns the actual number of items > without touching the output array. Some POSIX page recommends a sysconf > call but the former seems simpler. The problem is that I cannot pass the array as argument because it is not allocated yet. Sould I pass a dummy one, or can I pass a null pointer? -- Eric Bezault mailto:er...@go... http://www.gobosoft.com |