Re: [PATCH][next] btrfs: remove redundant initialization of variables leaf and slot

From: David Sterba
Date: Thu Jun 29 2023 - 11:32:47 EST


On Thu, Jun 22, 2023 at 08:54:30AM +0100, Colin Ian King wrote:
> The variables leaf and slot are initialized when declared but the values
> assigned to them are never read as they are being re-assigned later on.
> The initializations are redundant and can be removed. Cleans up clang
> scan build warings:
>
> fs/btrfs/tree-log.c:6797:25: warning: Value stored to 'leaf' during its
> initialization is never read [deadcode.DeadStores]
> fs/btrfs/tree-log.c:6798:7: warning: Value stored to 'slot' during its
> initialization is never read [deadcode.DeadStores]
>
> Signed-off-by: Colin Ian King <colin.i.king@xxxxxxxxx>

Added to misc-next, thanks.