This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
Re: getdents64 problem
Mogens Kjaer <mk@crc.dk> writes:
> I guess a lot of programs have this construction
>
> x=opendir("path");
> while((y=readdir(x))!=NULL)
> {
> do something
> }
> closedir(x);
>
> and it would fail silently when reading from an SGI via NFS,
> as one seldomly checks for errors when readdir has return NULL.
This is why everybody will have to compile programs with
_FILE_OFFSET_BITS=64. Did you ever notice that all GNU programs
already do this?
> That leaves me with two options, either patch the Linux
> kernel or glibc. I found it easier to do the second.
>
> What do the rest of you think?
You have to change the programs. There is no other way.
--
---------------. ,-. 1325 Chesapeake Terrace
Ulrich Drepper \ ,-------------------' \ Sunnyvale, CA 94089 USA
Red Hat `--' drepper at redhat.com `------------------------