On Wed, Jun 07, 2006 at 05:10:29PM -0700, Dave Hansen wrote: this is the first non-trivial change to the condition checks (regarding goto out_path_release) why didn't you break that out too? best, Herbert > Signed-off-by: Dave Hansen <haveblue@xxxxxxxxxx> > --- > > lxc-dave/fs/open.c | 16 ++++++++++++++-- > 1 files changed, 14 insertions(+), 2 deletions(-) > > diff -puN fs/open.c~elevate-writers-opens-part2-sys_faccessat2 fs/open.c > --- lxc/fs/open.c~elevate-writers-opens-part2-sys_faccessat2 2006-06-07 16:53:23.000000000 -0700 > +++ lxc-dave/fs/open.c 2006-06-07 16:53:23.000000000 -0700 > @@ -542,9 +542,21 @@ asmlinkage long sys_faccessat(int dfd, c > > res = vfs_permission(&nd, mode); > /* SuS v2 requires we report a read only fs too */ > - if(!res && (mode & S_IWOTH) && IS_RDONLY(nd.dentry->d_inode) > - && !special_file(nd.dentry->d_inode->i_mode)) > + if(res) > + goto out_path_release; > + if (!(mode & S_IWOTH)) > + goto out_path_release; > + if (special_file(nd.dentry->d_inode->i_mode)) > + goto out_path_release; > + > + res = mnt_want_write(nd.mnt); > + if (res) { > + mnt_drop_write(nd.mnt); > + goto out_path_release; > + } > + if (IS_RDONLY(nd.dentry->d_inode)) > res = -EROFS; > +out_path_release: > path_release(&nd); > > out: > _ - To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html