[Top][All Lists]

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

Re: st_nlink of directory nodes in shadowfs

From: Thomas Bushnell, BSG
Subject: Re: st_nlink of directory nodes in shadowfs
Date: 27 Oct 2001 17:49:45 -0700
User-agent: Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7

Roland McGrath <roland@gnu.org> writes:

> By my reading of 1003.1-1996, st_nlink should be "the number of directory
> entries that refer to the file".  In a case like this, I think it's pretty
> open to interpretation what constitutes a directory entry; there always
> might be extra entries in some directory you don't know about, and that is
> not distinguishable from st_nlink just being too high.

Unless there's a very good reason, I would like st_nlink on a
directory to always be the number of subdirectories plus two.  

If you have permissions on the directory, then there can't be entries
you don't know about, because we have an interface that promises the
whole list.

Posix is looser than this, as Roland points out, but absent a really
good reason (and "it's a bother to code" is probably not a really good
reason) we should provide consistent sane behavior.

reply via email to

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