diff options
author | наб <[email protected]> | 2021-12-23 20:39:29 +0100 |
---|---|---|
committer | GitHub <[email protected]> | 2021-12-23 11:39:29 -0800 |
commit | 1135d0a5fff42ab9a79a1117faa8481d55976a1e (patch) | |
tree | 3d24955c5278292c653408b891a06e84cc969e69 /module/os | |
parent | 18e4f67960a7ad4f7300bd868f24c8a9f90472b2 (diff) |
FreeBSD: fix unpropagated error
When performing I/O on FreeBSD using a file based vdev ensure all
errors encountered when reading/writing are propagated through the
zio pipeline.
Reviewed-by: Brian Behlendorf <[email protected]>
Reviewed-by: Alexander Motin <[email protected]>
Reviewed-by: Ryan Moeller <[email protected]>
Signed-off-by: Ahelenia Ziemiańska <[email protected]>
Closes #12904
Diffstat (limited to 'module/os')
-rw-r--r-- | module/os/freebsd/zfs/vdev_file.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/module/os/freebsd/zfs/vdev_file.c b/module/os/freebsd/zfs/vdev_file.c index cd1d75687..2d9268136 100644 --- a/module/os/freebsd/zfs/vdev_file.c +++ b/module/os/freebsd/zfs/vdev_file.c @@ -234,6 +234,7 @@ vdev_file_io_strategy(void *arg) err = zfs_file_pwrite(vf->vf_file, buf, size, off, &resid); abd_return_buf(zio->io_abd, buf, size); } + zio->io_error = err; if (resid != 0 && zio->io_error == 0) zio->io_error = ENOSPC; |