X-Git-Url: http://git.ipfire.org/?p=thirdparty%2Fmdadm.git;a=blobdiff_plain;f=Create.c;fp=Create.c;h=1e4a6ee065fde6a201bb1e356126cadf46ff711d;hp=40f1b7ea81be67015570ad0c4eefb067c162a245;hb=dfd7822ca686339f77ea808a4bdf2b085674e611;hpb=f170a5a9a0b5dbdd502b1014cfe040bf83da5ccf diff --git a/Create.c b/Create.c index 40f1b7ea..1e4a6ee0 100644 --- a/Create.c +++ b/Create.c @@ -330,7 +330,7 @@ int Create(struct supertype *st, char *mddev, } close(dfd); info.array.working_disks++; - if (dnum < s->raiddisks) + if (dnum < s->raiddisks && dv->disposition != 'j') info.array.active_disks++; if (st == NULL) { struct createinfo *ci = conf_get_create_info(); @@ -400,7 +400,7 @@ int Create(struct supertype *st, char *mddev, } if (dv->disposition == 'j') - continue; /* skip write journal for size check */ + goto skip_size_check; /* skip write journal for size check */ freesize /= 2; /* convert to K */ if (s->chunk && s->chunk != UnSet) { @@ -434,6 +434,7 @@ int Create(struct supertype *st, char *mddev, mindisc = dname; minsize = freesize; } + skip_size_check: if (c->runstop != 1 || c->verbose >= 0) { int fd = open(dname, O_RDONLY); if (fd <0 ) {