[lkml]   [2001]   [Jul]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
Patch in this message
SubjectRe: [NFS] [PATCH] Bug in NFS - should init be allowed to set umask???
On Friday July 13, wrote:
> On Sat, 14 Jul 2001, Neil Brown wrote:
> >
> > I've found a 4th option. We make it so that fs->umask does not affect
> > nfsd
> Me likee.
> Applied. I'd only like to double-check that you made sure you changed all
> callers?

There is just the call to vfs_mknod in net/unix/af_unix.c that I
mentioned. I'm not sure what to do about that one.

find -name '*.[ch]' | xargs egrep 'vfs_(mkdir|mknod|create)'

4 matches in fs/nfsd/vfs.c which I explicitly didn't want to change
6 matches in fs/devfs/base.c which were really matches for devfs_(mkdir|mknod)
7 matches in fs/namei.c which the patch changed
3 matches in kernel/ksyms.c which are EXPORT_SYMBOLs, not calls
3 matches in include/linux/fs.h which are declatations
2 matches in net/unix/af_unix.c one is a comment, the other is the
one in question

To be maximally conservative, you might want to apply this patch,
just in case it is important.


--- ./net/unix/af_unix.c 2001/07/14 04:43:58 1.1
+++ ./net/unix/af_unix.c 2001/07/14 04:46:39
@@ -714,7 +714,7 @@
* All right, let's create it.
err = vfs_mknod(nd.dentry->d_inode, dentry,
- S_IFSOCK|sock->inode->i_mode, 0);
+ (S_IFSOCK|sock->inode->i_mode) & ~current->fs->umask, 0);
if (err)
goto out_mknod_dput;
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at
 \ /
  Last update: 2005-03-22 12:57    [W:0.095 / U:0.188 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site