[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20191007150340.GA2751@twin.jikos.cz>
Date: Mon, 7 Oct 2019 17:03:40 +0200
From: David Sterba <dsterba@...e.cz>
To: Austin Kim <austindh.kim@...il.com>
Cc: clm@...com, josef@...icpanda.com, dsterba@...e.com,
linux-btrfs@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] btrfs: fix Wmaybe-uninitialized warning
On Tue, Sep 03, 2019 at 12:30:19PM +0900, Austin Kim wrote:
> gcc throws warning message as below:
>
> ‘clone_src_i_size’ may be used uninitialized in this function
> [-Wmaybe-uninitialized]
> #define IS_ALIGNED(x, a) (((x) & ((typeof(x))(a) - 1)) == 0)
> ^
> fs/btrfs/send.c:5088:6: note: ‘clone_src_i_size’ was declared here
> u64 clone_src_i_size;
> ^
> The clone_src_i_size is only used as call-by-reference
> in a call to get_inode_info().
>
> Silence the warning by initializing clone_src_i_size to 0.
>
> Signed-off-by: Austin Kim <austindh.kim@...il.com>
A few more people have repoted this warning, so I'm gonig to apply the
patch to avoid further reports. Thanks.
Powered by blists - more mailing lists