From 964e1845022cb5581ecfa674a3219d8c8443009a Mon Sep 17 00:00:00 2001 From: Neil Brown Date: Thu, 1 Nov 2007 16:50:20 +1100 Subject: [PATCH] --- yaml --- r: 74172 b: refs/heads/master c: 4c1fe2f78a08e2c514a39c91a0eb7b55bbd3c0d2 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/fs/nfs/super.c | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/[refs] b/[refs] index 278139196d69..7bd8d7683710 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: eda4f9b7996e5520934ca2a7310b363463a4e3b0 +refs/heads/master: 4c1fe2f78a08e2c514a39c91a0eb7b55bbd3c0d2 diff --git a/trunk/fs/nfs/super.c b/trunk/fs/nfs/super.c index fa517ae9207f..71067d1ac9d9 100644 --- a/trunk/fs/nfs/super.c +++ b/trunk/fs/nfs/super.c @@ -1474,6 +1474,11 @@ static int nfs_xdev_get_sb(struct file_system_type *fs_type, int flags, error = PTR_ERR(mntroot); goto error_splat_super; } + if (mntroot->d_inode->i_op != &nfs_dir_inode_operations) { + dput(mntroot); + error = -ESTALE; + goto error_splat_super; + } s->s_flags |= MS_ACTIVE; mnt->mnt_sb = s;