Eric:
> 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?
thanks for your changes!
that's my understanding, it does say the array parameter is not going to
be touched, the point of the call with zero is to get the size so that
you can allocate enough space for next time you call with a real array
so I think you can call with null instead of a dummy array.
I'd also check that the call with zero doesn't return <= 0 to avoid
negative/zero malloc (though it might cope).
next problem is the lack of pwd.h and grp.h that define populated
versions of the passwd and group structures used by getgrgid and
getpwuid. I don't know for sure if it's portable, but it is in POSIX so
should be a fair bet.
and that's the last one, bootstrap worked after patching eif_file.c for
this.
|