diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2013-03-08 12:03:07 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-03-08 12:03:07 -0500 |
commit | 7b54c165a0c012edbaeaa73c5c87cb73721eb580 (patch) | |
tree | c44ffe65534057860a73226d28dac1d4e6ea9ac7 /fs/namei.c | |
parent | 47b3bc907328db968bc9b43c41f48f8d1e140750 (diff) |
vfs: don't BUG_ON() if following a /proc fd pseudo-symlink results in a symlink
It's "normal" - it can happen if the file descriptor you followed was
opened with O_NOFOLLOW.
Reported-by: Dave Jones <davej@redhat.com>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Cc: stable@kernel.org
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/namei.c')
-rw-r--r-- | fs/namei.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/fs/namei.c b/fs/namei.c index 961bc1268366..57ae9c8c66bf 100644 --- a/fs/namei.c +++ b/fs/namei.c | |||
@@ -689,8 +689,6 @@ void nd_jump_link(struct nameidata *nd, struct path *path) | |||
689 | nd->path = *path; | 689 | nd->path = *path; |
690 | nd->inode = nd->path.dentry->d_inode; | 690 | nd->inode = nd->path.dentry->d_inode; |
691 | nd->flags |= LOOKUP_JUMPED; | 691 | nd->flags |= LOOKUP_JUMPED; |
692 | |||
693 | BUG_ON(nd->inode->i_op->follow_link); | ||
694 | } | 692 | } |
695 | 693 | ||
696 | static inline void put_link(struct nameidata *nd, struct path *link, void *cookie) | 694 | static inline void put_link(struct nameidata *nd, struct path *link, void *cookie) |