[PATCH v2 2/4] xfs_db: fix unitialized automatic struct ifake to 0.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Ensure automatic struct ifake is properly initialized.

Coverity-id: 1596600, 1596597

Signed-off-by: Bill O'Donnell <bodonnel@xxxxxxxxxx>
---
 db/bmap_inflate.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/db/bmap_inflate.c b/db/bmap_inflate.c
index 33b0c954..219f9bbf 100644
--- a/db/bmap_inflate.c
+++ b/db/bmap_inflate.c
@@ -340,7 +340,7 @@ build_new_datafork(
 	const struct xfs_bmbt_irec	*irec,
 	xfs_extnum_t			nextents)
 {
-	struct xbtree_ifakeroot		ifake;
+	struct xbtree_ifakeroot		ifake = {};
 	struct xfs_btree_cur		*bmap_cur;
 	int				error;
 
@@ -394,7 +394,7 @@ estimate_size(
 		.leaf_slack		= 1,
 		.node_slack		= 1,
 	};
-	struct xbtree_ifakeroot		ifake;
+	struct xbtree_ifakeroot		ifake = {};
 	struct xfs_btree_cur		*bmap_cur;
 	int				error;
 
-- 
2.45.2





[Index of Archives]     [XFS Filesystem Development (older mail)]     [Linux Filesystem Development]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux RAID]     [Linux SCSI]


  Powered by Linux