Subject: Re: funlink() for fun!
To: Greywolf <>
From: Greg A. Woods <>
List: tech-kern
Date: 07/12/2003 13:57:55
[ On Saturday, July 12, 2003 at 02:11:14 (-0700), Greywolf wrote: ]
> Subject: Re: funlink() for fun!
> Greg, file descriptors are not associated with pathnames.  There is no
> "proper directory entry".

How is it that suddenly you have absolutely no imagination at all?

File descriptors are associated with files.

Filenames are associated with files.

If you can't make the connection implied by these two axioms then I
would humbly suggest you're not seeing the whole picture with even
remotely enough clarity and understanding to make this discussion useful
or interesting.

> You want a 1:1 relationship between filehandles and pathnames, more or
> less.

No, I absolutely do not.  If you think this then by now I can only
conclude that you have not read all of what I wrote carefully enough.

However I do know that for the case where a file has a link count of
exactly one then there is guaranteed to be a one-to-one relationship
with one particular pathname in the directory tree of the filesystem
that file belongs to.  Because of this guaranteed truth I know that it
is possible, if somewhat costly, to implement funlink() as I've
described it such that it could be safe and useful to use in the vast
majority of situations where it might make sense to be used.  I also
know that one could spread the cost around a little bit and further
increase the reliability of funlink(), as I've described it.

								Greg A. Woods

+1 416 218-0098;            <>;           <>
Planix, Inc. <>; VE3TCP; Secrets of the Weird <>