From: Chuck Lever Date: Fri, 20 Oct 2006 06:28:42 +0000 (-0700) Subject: [PATCH] NFS: remove unused check in nfs4_open_revalidate X-Git-Tag: v2.6.19-rc3~85 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=b87c0adfeaaf8d8310c4f790d76072a5961b3518;p=platform%2Fkernel%2Flinux-exynos.git [PATCH] NFS: remove unused check in nfs4_open_revalidate Coverity spotted a superfluous error check in nfs4_open_revalidate(). Remove it. Coverity: #cid 847 Test plan: Code inspection; another pass through Coverity. Signed-off-by: Chuck Lever Signed-off-by: Trond Myklebust Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c index 47c7e6e..7421bcb 100644 --- a/fs/nfs/nfs4proc.c +++ b/fs/nfs/nfs4proc.c @@ -1314,11 +1314,9 @@ nfs4_open_revalidate(struct inode *dir, struct dentry *dentry, int openflags, st case -EROFS: lookup_instantiate_filp(nd, (struct dentry *)state, NULL); return 1; - case -ENOENT: - if (dentry->d_inode == NULL) - return 1; + default: + goto out_drop; } - goto out_drop; } if (state->inode == dentry->d_inode) { nfs4_intent_set_file(nd, dentry, state);