Assemble: get content before testing it.
When checking that a container matches the required uuid, we need to call 'getinfo_super' before we have a 'content' to test. Reported-by: "Czarnowska, Anna" <anna.czarnowska@intel.com> Signed-off-by: NeilBrown <neilb@suse.de>
This commit is contained in:
parent
062dc4817d
commit
87477e6d5e
|
@ -409,6 +409,11 @@ int Assemble(struct supertype *st, char *mddev,
|
|||
if (ident->container[0] != '/') {
|
||||
/* we have a uuid */
|
||||
int uuid[4];
|
||||
|
||||
content = &info;
|
||||
memset(content, 0, sizeof(*content));
|
||||
tst->ss->getinfo_super(tst, content, NULL);
|
||||
|
||||
if (!parse_uuid(ident->container, uuid) ||
|
||||
!same_uuid(content->uuid, uuid, tst->ss->swapuuid)) {
|
||||
if (report_missmatch)
|
||||
|
|
Loading…
Reference in New Issue