diff options
author | Ryan Moeller <[email protected]> | 2022-02-18 16:09:03 -0500 |
---|---|---|
committer | GitHub <[email protected]> | 2022-02-18 13:09:03 -0800 |
commit | e41013078a90d5790c737eec573ec376ca21a234 (patch) | |
tree | 226e3cc7cd664a8354f8d19b9c578c48ac746916 /module | |
parent | a014378dd010fb4f9bf5ab003bd27526ff898952 (diff) |
libzfs: Fail making a dataset handle gracefully
When a dataset is in the process of being received it gets marked as
inconsistent and should not be used. We should check for this when
opening a dataset handle in libzfs and return with an appropriate error
set, rather than hitting an abort because of the incomplete data.
zfs_open() passes errno to zfs_standard_error() after observing
make_dataset_handle() fail, which ends up aborting if errno is 0.
Set errno before returning where we know it has not been set already.
Reviewed-by: Brian Behlendorf <[email protected]>
Signed-off-by: Ryan Moeller <[email protected]>
Closes #13077
Diffstat (limited to 'module')
0 files changed, 0 insertions, 0 deletions