bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: coreutils-6.0 on platforms without fchdir


From: Jim Meyering
Subject: Re: coreutils-6.0 on platforms without fchdir
Date: Sat, 02 Sep 2006 00:40:33 +0200

Paul Eggert <address@hidden> wrote:
> Thanks for working on it, but I think we'd prefer a solution that
> doesn't require the maintainer having to think about obsolete
> platforms that lack fchdir.
>
> How about the following idea instead?  On platforms lacking fchdir,
> put a wrapper around 'open' so that we can keep track of which file
> descriptors correspond to directories.  The 'open' wrapper puts the
> name of the opened directory into a hash table.  (The name must be
...

That sounds like a fine compromise.  As I recall, that's the gist of what
Cygwin did to provide fchdir support.  And since BeOS seems to be a fringe
system (i.e., nearly museum-only), no one will notice the performance hit.

A fundamental goal in coreutils development has been to code to the most
modern/useful/portable interfaces.  Anything else should be hidden as far
under the covers as possible.  That's one of the reasons there are so
many replacement functions in coreutils and gnulib and so few #ifdefs
in coreutils/src/*.c.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]