From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andrew Price Date: Tue, 10 May 2016 15:43:11 +0100 Subject: [Cluster-devel] [PATCH 2/2] gfs2_edit savemeta: Fix use of uninitialized 'blk' In-Reply-To: <1462891391-19942-1-git-send-email-anprice@redhat.com> References: <1462891391-19942-1-git-send-email-anprice@redhat.com> Message-ID: <1462891391-19942-2-git-send-email-anprice@redhat.com> List-Id: To: cluster-devel.redhat.com MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Fixes "savemeta.c:737:14: warning: ?blk? may be used uninitialized in this function" blk is never actually used uninitialized here but the compiler can't reason it out, so make it explicit to silence the warning. Signed-off-by: Andrew Price --- gfs2/edit/savemeta.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gfs2/edit/savemeta.c b/gfs2/edit/savemeta.c index 8510d77..db9a947 100644 --- a/gfs2/edit/savemeta.c +++ b/gfs2/edit/savemeta.c @@ -712,7 +712,7 @@ static void get_journal_inode_blocks(void) static void save_allocated(struct rgrp_tree *rgd, struct metafd *mfd) { int blktype; - uint64_t blk; + uint64_t blk = 0; unsigned i, j, m; uint64_t *ibuf = malloc(sbd.bsize * GFS2_NBBY * sizeof(uint64_t)); -- 2.4.11