summaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorAnna Schumaker <Anna.Schumaker@Netapp.com>2017-01-11 16:30:08 -0500
committerAnna Schumaker <Anna.Schumaker@Netapp.com>2017-01-30 13:14:50 -0500
commit9df1336ca42c16622f1cae5dff246a0c9c644514 (patch)
treef98be7f1e17798d3cac4c3bc86477e1065821962 /fs
parent334f87dd11b7a0ed8f3d3b223fb5cede201e210a (diff)
downloadlinux-0-day-9df1336ca42c16622f1cae5dff246a0c9c644514.tar.gz
linux-0-day-9df1336ca42c16622f1cae5dff246a0c9c644514.tar.xz
NFS: Remove unnecessary goto in nfs4_lookup_root_sec()
Once again, it's easier and cleaner just to return the error directly. Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
Diffstat (limited to 'fs')
-rw-r--r--fs/nfs/nfs4proc.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c
index baf9689904752..6c40944cb83de 100644
--- a/fs/nfs/nfs4proc.c
+++ b/fs/nfs/nfs4proc.c
@@ -3416,16 +3416,11 @@ static int nfs4_lookup_root_sec(struct nfs_server *server, struct nfs_fh *fhandl
.pseudoflavor = flavor,
};
struct rpc_auth *auth;
- int ret;
auth = rpcauth_create(&auth_args, server->client);
- if (IS_ERR(auth)) {
- ret = -EACCES;
- goto out;
- }
- ret = nfs4_lookup_root(server, fhandle, info);
-out:
- return ret;
+ if (IS_ERR(auth))
+ return -EACCES;
+ return nfs4_lookup_root(server, fhandle, info);
}
/*