lkml.org 
[lkml]   [2024]   [Apr]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] lockd: host: Remove unnecessary statements'host = NULL;'
On Wed, Apr 17, 2024 at 04:28:07PM +0800, Li kunyu wrote:
> 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>
> ---
> fs/lockd/host.c | 1 -
> 1 file changed, 1 deletion(-)
>
> diff --git a/fs/lockd/host.c b/fs/lockd/host.c
> index 127a728fcbc81..c115168017845 100644
> --- a/fs/lockd/host.c
> +++ b/fs/lockd/host.c
> @@ -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)) {
> --
> 2.18.2
>

Thanks for the clean up! Applied to nfsd-next (for v6.10).

--
Chuck Lever

\
 
 \ /
  Last update: 2024-04-17 18:29    [W:0.043 / U:0.512 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site