diff options
author | Trond Myklebust <Trond.Myklebust@netapp.com> | 2005-06-07 18:37:01 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-06-07 15:53:47 -0700 |
commit | 1d6757fbff5bc86e94e59ab0d7bdd7e71351d839 (patch) | |
tree | 65e75b32e0810961615101cb1f137a060c707c6b /fs/sysfs/sysfs.h | |
parent | eba4f669d6ec9be4173bb2619e9b8500b3c36542 (diff) | |
download | op-kernel-dev-1d6757fbff5bc86e94e59ab0d7bdd7e71351d839.zip op-kernel-dev-1d6757fbff5bc86e94e59ab0d7bdd7e71351d839.tar.gz |
[PATCH] NFS: Fix lookup intent handling
We should never apply a lookup intent to anything other than the last
path component in an open(), create() or access() call.
Introduce the helper nfs_lookup_check_intent() which always returns
zero if LOOKUP_CONTINUE or LOOKUP_PARENT are set, and returns the
intent flags if we're on the last component of the lookup.
By doing so, we fix a bug in open(O_EXCL), where we may end up
optimizing away a real lookup of the parent directory.
Problem noticed by Linda Dunaphant <linda.dunaphant@ccur.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs/sysfs/sysfs.h')
0 files changed, 0 insertions, 0 deletions