diff --git a/module/zfs/zfs_ioctl.c b/module/zfs/zfs_ioctl.c index 8064edd6cc..2fd836a4ae 100644 --- a/module/zfs/zfs_ioctl.c +++ b/module/zfs/zfs_ioctl.c @@ -1639,9 +1639,10 @@ zfs_ioc_objset_stats(struct file *filp, zfs_cmd_t *zc) */ if (!zc->zc_objset_stats.dds_inconsistent) { if (dmu_objset_type(os) == DMU_OST_ZVOL) - VERIFY(zvol_get_stats(os, nv) == 0); + error = zvol_get_stats(os, nv); } - error = put_nvlist(zc, nv); + if (error == 0) + error = put_nvlist(zc, nv); nvlist_free(nv); }