martin f. krafft: Initialise the devnum variable to prevent compiler error

Martin F. Krafft madduck at alioth.debian.org
Fri Jul 29 14:28:26 UTC 2011


Module: mdadm
Branch: patch-queue/master
Commit: 3ac24179a07565f1d85c358b9c074be271e0aeba
URL:    http://git.debian.org/?p=pkg-mdadm/mdadm.git;a=commit;h=3ac24179a07565f1d85c358b9c074be271e0aeba

Author: martin f. krafft <madduck at debian.org>
Date:   Fri Jul 29 12:12:57 2011 +0200

Initialise the devnum variable to prevent compiler error

Due to -Werror, the compile fails due to the possibility of devnum not
being initialised.

Signed-off-by: martin f. krafft <madduck at debian.org>

---

 super-intel.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/super-intel.c b/super-intel.c
index 2ef2b3c..71c3164 100644
--- a/super-intel.c
+++ b/super-intel.c
@@ -8657,7 +8657,7 @@ static int imsm_reshape_super(struct supertype *st, long long size, int level,
 		 */
 		struct intel_super *super = st->sb;
 		struct intel_dev *dev = super->devlist;
-		int change, devnum;
+		int change, devnum=0;
 		dprintf("imsm: info: Volume operation\n");
 		/* find requested device */
 		while (dev) {




More information about the pkg-mdadm-commits mailing list