DDF: fix writing metadata updates.
Recent commit 273989b93a
skipped writing some large blocks of 0xFF, but didn't seek
over the space, so subsequent data was written wrongly.
When we don't write, we need to seek.
Signed-off-by: NeilBrown <neilb@suse.de>
This commit is contained in:
parent
57631ca2ff
commit
ce45c81986
|
@ -2907,7 +2907,8 @@ static int __write_ddf_structure(struct dl *d, struct ddf_super *ddf, __u8 type,
|
|||
}
|
||||
if (write(fd, null_aligned, togo) < 0)
|
||||
break;
|
||||
}
|
||||
} else
|
||||
lseek(fd, conf_size, SEEK_CUR);
|
||||
}
|
||||
if (i <= n_config)
|
||||
goto out;
|
||||
|
|
Loading…
Reference in New Issue