On Sun, 12 Dec 1999, Andreas Gruenbacher wrote:

> Alexander Viro wrote:
> > 
> > First of all, why do you need the full permissions? Anyway, _if_ you
> > really need it - that's not a way to go. Really. Minimal solution would go
> > along the lines
> 
> The full permissions are indeed necessary for file/directory creation inside a
> directory that has a default ACL. This is specified in Posix 1003.1e Draft
> Standard 17 (withdrawn), <http://www.guug.de/~winni/posix.1e/download.html>.
              ^^^^^^^^^^^
...ahem.

> What we did was move the umask merging code that was in the VFS into the
> filesystem code. In ext2, that also cleaned up some oddities around
> ext2_new_inode(). The patch was designed not to change the semantics of the
> current code.
 
> Your function really does a different thing (which doesn't mean it shouldn't be
> done).

It does the same, but it doesn't add code duplication. It should be called
from foo_new_inode() and it has the additional benefit of making
credentials-passing easier to implement. Code duplication is evil. Really.

Reply via email to