Nathan Chancellor <nat...@kernel.org> wrote:

> This change as commit 1bd9011ee163 ("netfs: Change the read result
> collector to only use one work item") in next-20241114 causes a clang
> warning:
> 
>   fs/netfs/read_retry.c:235:20: error: variable 'subreq' is uninitialized 
> when used here [-Werror,-Wuninitialized]
>     235 |         if (list_is_last(&subreq->rreq_link, &stream->subrequests))
>         |                           ^~~~~~
>   fs/netfs/read_retry.c:28:36: note: initialize the variable 'subreq' to 
> silence this warning
>      28 |         struct netfs_io_subrequest *subreq;
>         |                                           ^
>         |                                            = NULL
> 
> May be a shadowing issue, as adding KCFLAGS=-Wshadow shows:

Yep.  I'll remove both shadowing variables (there's also one at line 45 in the
bit that deals with the non-renegotiation case) and use the outermost one.

Thanks,
David

Reply via email to