Re: ANNOUNCE: mdadm 2.5.1 - A tool for managing Soft RAID under Linux

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

 



Neil Brown wrote:

I am pleased to announce the availability of
   mdadm version 2.5.1

Hi Neil,

Here's a small patch to allow compilation on gcc 2.x. It looks like gcc 3.x allows variable declarations that are not at the start of a block of code (I don't know if there's some standard that allows that in C code now, but it doesn't work with all C compilers).

Patch attached.

Thanks,
Paul
--- mdadm-2.5.1/super1.c.orig	Fri Jun 16 11:27:16 2006
+++ mdadm-2.5.1/super1.c	Fri Jun 16 11:28:20 2006
@@ -309,6 +309,7 @@ static void brief_examine_super1(void *s
 	struct mdp_superblock_1 *sb = sbv;
 	int i;
 	char *nm;
+	char *c=map_num(pers, __le32_to_cpu(sb->level));
 
 	nm = strchr(sb->set_name, ':');
 	if (nm)
@@ -317,8 +318,6 @@ static void brief_examine_super1(void *s
 		nm = sb->set_name;
 	else
 		nm = "??";
-
-	char *c=map_num(pers, __le32_to_cpu(sb->level));
 
 	printf("ARRAY /dev/md/%s level=%s metadata=1 num-devices=%d UUID=",
 	       nm,

[Index of Archives]     [Linux RAID Wiki]     [ATA RAID]     [Linux SCSI Target Infrastructure]     [Linux Block]     [Linux IDE]     [Linux SCSI]     [Linux Hams]     [Device Mapper]     [Device Mapper Cryptographics]     [Kernel]     [Linux Admin]     [Linux Net]     [GFS]     [RPM]     [git]     [Yosemite Forum]


  Powered by Linux