]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
lockd: host: Remove unnecessary statements'host = NULL;'
authorLi kunyu <kunyu@nfschina.com>
Wed, 17 Apr 2024 08:28:07 +0000 (16:28 +0800)
committerChuck Lever <chuck.lever@oracle.com>
Mon, 6 May 2024 13:07:20 +0000 (09:07 -0400)
In 'nlm_alloc_host', the host has already been assigned a value of NULL
when defined, so 'host=NULL;' Can be deleted.

Signed-off-by: Li kunyu <kunyu@nfschina.com>
Reviewed-by: Jeff Layton <jlayton@kernel.org>
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
fs/lockd/host.c

index 127a728fcbc81ee24040fafb79260dfaea918e80..c115168017845a4dc43492a991f5699769d36400 100644 (file)
@@ -117,7 +117,6 @@ static struct nlm_host *nlm_alloc_host(struct nlm_lookup_host_info *ni,
        if (nsm != NULL)
                refcount_inc(&nsm->sm_count);
        else {
-               host = NULL;
                nsm = nsm_get_handle(ni->net, ni->sap, ni->salen,
                                        ni->hostname, ni->hostname_len);
                if (unlikely(nsm == NULL)) {