mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-09-22 12:44:11 +08:00
NFS check the return of nfs4_negotiate_security in nfs4_submount
Signed-off-by: Andy Adamson <andros@netapp.com> Tested-By: Steve Dickson <steved@redhat.com> Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
This commit is contained in:
parent
6edf96097b
commit
57bbe3d7c1
@ -399,8 +399,11 @@ struct vfsmount *nfs4_submount(struct nfs_server *server, struct dentry *dentry,
|
|||||||
flavor = client->cl_auth->au_flavor;
|
flavor = client->cl_auth->au_flavor;
|
||||||
else {
|
else {
|
||||||
rpc_authflavor_t new = nfs4_negotiate_security(dir, name);
|
rpc_authflavor_t new = nfs4_negotiate_security(dir, name);
|
||||||
if ((int)new >= 0)
|
if ((int)new < 0) {
|
||||||
flavor = new;
|
mnt = ERR_PTR((int)new);
|
||||||
|
goto out;
|
||||||
|
}
|
||||||
|
flavor = new;
|
||||||
}
|
}
|
||||||
mnt = nfs_do_submount(dentry, fh, fattr, flavor);
|
mnt = nfs_do_submount(dentry, fh, fattr, flavor);
|
||||||
out:
|
out:
|
||||||
|
Loading…
Reference in New Issue
Block a user