Re: [PATCH v2] kernel/sysctl.c: drop unneeded assignment in proc_do_large_bitmap()

Kees Cook <[email protected]> Wed, 7 Oct 2020 11:44:06 -0700
Newsgroups tech.elisa.lists.linux-safety,org.kernel.vger.linux-fsdevel,org.kernel.vger.linux-kernel
Message-ID <202010071144.FA87F25D5D@keescook>
On Wed, Oct 07, 2020 at 04:19:04PM +0100, Sudip Mukherjee wrote:
> The variable 'first' is assigned 0 inside the while loop in the if block
> but it is not used in the if block and is only used in the else block.
> So, remove the unneeded assignment and move the variable in the else block.
> 
> Signed-off-by: Sudip Mukherjee <[email protected]>

Reviewed-by: Kees Cook <[email protected]>

-- 
Kees Cook