Use zfs_read() instead of xfsread() to read /boot.config. xfsread() fails
short read requests, so the result was that a /boot.config smaller than 512 bytes was ignored. boot2 uses fsread() instead of xfsread() to read /boot.config already, so this makes zfsboot more like boot2. Submitted by: Johny Mattsson johny-freebsd of earthmagic org Reviewed by: dfr MFC after: 3 days
This commit is contained in:
parent
14c129fc3e
commit
a944fb4cc3
@ -609,7 +609,7 @@ main(void)
|
||||
|
||||
if (zfs_lookup(spa, PATH_CONFIG, &dn) == 0) {
|
||||
off = 0;
|
||||
xfsread(&dn, &off, cmd, sizeof(cmd));
|
||||
zfs_read(spa, &dn, &off, cmd, sizeof(cmd));
|
||||
}
|
||||
|
||||
if (*cmd) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user