This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH] Linux: Add getdents64 system call
* Adhemerval Zanella:
> My understanding is lseek from getdirentries is not really useless, but
> exactly the semantic it aims to provide. Linux getdents does not have
> the concept of offset, different than BSDs one which is usually
> syscall (FreeBSD for instance).
It's not a real offset in FreeBSD, either, in the sense that you can
perform arithmetic on it. Our implementation is not compatible because
it does not perform a NULL check and assumes that the pointer to the
base offset is always non-NULL.
> I am not sure, however, who usefull this is in reality. On FreeBSD repo
> (not including ports), I see few uses: sdiff tool is the only binary and
> opendir seems call it internally.
I think providing this function is also misleading because there are
differences in parsing the directory stream.
Thanks,
Florian