Subject: Re: CVS commit: src
To: Reinoud Zandijk <reinoud@netbsd.org>
From: Eric Haszlakiewicz <erh@jodi.nimenees.com>
List: tech-kern
Date: 06/29/2005 16:00:58
On Wed, Jun 29, 2005 at 09:22:16AM -0700, Bill Studenmund wrote:
> On Wed, Jun 29, 2005 at 04:13:38AM +0200, Reinoud Zandijk wrote:
> > On Tue, Jun 28, 2005 at 06:04:16PM -0700, Bill Studenmund wrote:
> > > > So they are listable? and a directory then represented like=20
> > > > /path/to/regular/directory/..namedfork/* ?
> > >=20
> > > No, nor should they be. The file listing is of files, not parts of fi=
les.=20
> > > Thus they don't belong. :-)
> >=20
> > really?
>=20
> Yes. Mainly as if we start listing all of the files + sub extensions that=
=20
> we can open, we can very quickly (in my opinion) lose ourselves in a mess=
y=20
> sea of file "names."

	That's a silly way of looking at it.  The sub extensions wouldn't be
visible unless you explicitly asked for it.  i.e. getdirents() on /bin
would return the normal listing of files without the special directory ..na=
medfork,
but an opendir() on /bin/cat/..namedfork would work and you'd be able to do=
 a
getdirents on that.

	There are filesystems that do something very similar to this except
with "foo@@" being the magic hidden directory for "foo".  From my experience
with that it works pretty well (provided you don't have filenames that end =
in @@)
since most programs treat files as files, but if you explicitly use one of
those special names the program accessing the contents doesn't have to
know that anything is different from a normal directory hierarchy.

eric