Assemble: No need for dummy NULL pointer when calling map_update()
assemble_container_content() doesn't need a dummy NULL pointer variable for calling map_update. Passing NULL directly is sufficient. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com>
This commit is contained in:
parent
0a8e239c18
commit
0c79d8ca10
|
@ -1880,7 +1880,6 @@ int assemble_container_content(struct supertype *st, int mdfd,
|
||||||
struct mdinfo *dev, *sra, *dev2;
|
struct mdinfo *dev, *sra, *dev2;
|
||||||
int working = 0, preexist = 0;
|
int working = 0, preexist = 0;
|
||||||
int expansion = 0;
|
int expansion = 0;
|
||||||
struct map_ent *map = NULL;
|
|
||||||
int old_raid_disks;
|
int old_raid_disks;
|
||||||
int start_reshape;
|
int start_reshape;
|
||||||
char *avail;
|
char *avail;
|
||||||
|
@ -1949,11 +1948,9 @@ int assemble_container_content(struct supertype *st, int mdfd,
|
||||||
free(avail);
|
free(avail);
|
||||||
return 1;/* Nothing new, don't try to start */
|
return 1;/* Nothing new, don't try to start */
|
||||||
}
|
}
|
||||||
map_update(&map, fd2devnm(mdfd),
|
map_update(NULL, fd2devnm(mdfd), content->text_version,
|
||||||
content->text_version,
|
|
||||||
content->uuid, chosen_name);
|
content->uuid, chosen_name);
|
||||||
|
|
||||||
|
|
||||||
if (enough(content->array.level, content->array.raid_disks,
|
if (enough(content->array.level, content->array.raid_disks,
|
||||||
content->array.layout, content->array.state & 1, avail) == 0) {
|
content->array.layout, content->array.state & 1, avail) == 0) {
|
||||||
if (c->export && result)
|
if (c->export && result)
|
||||||
|
|
Loading…
Reference in New Issue