xfsdump: Initialize getbmap structure in quantity2offset
Prevent uninitialized data in the stack by initializing getbmap structure
to zero.
Signed-off-by: Carlos Maiolino <cmaiolino@redhat.com>
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
Signed-off-by: Carlos Maiolino <cem@kernel.org>
diff --git a/dump/inomap.c b/dump/inomap.c
index f3200be..c4ea21d 100644
--- a/dump/inomap.c
+++ b/dump/inomap.c
@@ -1627,7 +1627,7 @@
quantity2offset(jdm_fshandle_t *fshandlep, struct xfs_bstat *statp, off64_t qty)
{
int fd;
- struct getbmap bmap[BMAP_LEN];
+ struct getbmap bmap[BMAP_LEN] = {0};
off64_t offset;
off64_t offset_next;
off64_t qty_accum;