NFS: Don't leak RPC clients in NFSv4 secinfo negotiation
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
This commit is contained in:
parent
4d65c520fb
commit
a0e7e3cf79
|
@ -192,13 +192,15 @@ static rpc_authflavor_t nfs_lookup_with_sec(struct nfs_server *server, struct de
|
||||||
auth = rpcauth_create(flavor, clone);
|
auth = rpcauth_create(flavor, clone);
|
||||||
if (!auth) {
|
if (!auth) {
|
||||||
flavor = -EIO;
|
flavor = -EIO;
|
||||||
goto out;
|
goto out_shutdown;
|
||||||
}
|
}
|
||||||
err = server->nfs_client->rpc_ops->lookup(clone, parent->d_inode,
|
err = server->nfs_client->rpc_ops->lookup(clone, parent->d_inode,
|
||||||
&path->dentry->d_name,
|
&path->dentry->d_name,
|
||||||
fh, fattr);
|
fh, fattr);
|
||||||
if (err < 0)
|
if (err < 0)
|
||||||
flavor = err;
|
flavor = err;
|
||||||
|
out_shutdown:
|
||||||
|
rpc_shutdown_client(clone);
|
||||||
out:
|
out:
|
||||||
return flavor;
|
return flavor;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue