]> git.ipfire.org Git - thirdparty/mdadm.git/commitdiff
Fix bug in forced assemble.
authorChris Webb <chris@arachsys.com>
Thu, 19 Jun 2008 06:30:39 +0000 (16:30 +1000)
committerNeil Brown <neilb@suse.de>
Thu, 19 Jun 2008 06:30:39 +0000 (16:30 +1000)
From: Chris Webb <chris@arachsys.com>

We are loading into the already-loaded 'st' instead of the
newly create 'tst', which is clearly wrong.

Assemble.c

index 36b230435851b9449d78f02fa4952736717007cd..79f091269e68f843cbf9bd03978b8c739f3cf80c 100644 (file)
@@ -656,7 +656,7 @@ int Assemble(struct supertype *st, char *mddev, int mdfd,
                        continue;
                }
                tst = dup_super(st);
-               if (tst->ss->load_super(st,fd, NULL)) {
+               if (tst->ss->load_super(tst,fd, NULL)) {
                        close(fd);
                        fprintf(stderr, Name ": RAID superblock disappeared from %s - not updating.\n",
                                devices[chosen_drive].devname);