summaryrefslogtreecommitdiffstats
path: root/cddl
diff options
context:
space:
mode:
authorpjd <pjd@FreeBSD.org>2010-08-29 20:18:06 +0000
committerpjd <pjd@FreeBSD.org>2010-08-29 20:18:06 +0000
commit0926b8ce7cab5678099cc6f156d7fefd67eaab85 (patch)
tree896f5a5d6fe55c73873e1eeae8ae57b16acb19ff /cddl
parentff0f13be619dafe05ca0a216f79368d4c793a420 (diff)
downloadFreeBSD-src-0926b8ce7cab5678099cc6f156d7fefd67eaab85.zip
FreeBSD-src-0926b8ce7cab5678099cc6f156d7fefd67eaab85.tar.gz
Fix 'zfs allow' (maybe not only) returning:
cannot access dataset system/usr/home: Operation not supported by including libzfs_impl.h. What libzfs_impl.h does is to redefine ioctl() to be compatible with OpenSolaris. More specifically OpenSolaris returns ENOMEM when buffer is too small and sets field zc_nvlist_dst_size to the size that will be big enough for the data. In FreeBSD case ioctl() doesn't copy data structure back in case of a failure. We work-around it in kernel and libzfs by returning 0 from ioctl() and always checking if zc_nvlist_dst_size hasn't changed. For this work-around to work in pyzfs we need this compatible ioctl() which is implemented in libzfs_impl.h. MFC after: 2 weeks
Diffstat (limited to 'cddl')
-rw-r--r--cddl/contrib/opensolaris/lib/pyzfs/common/ioctl.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/cddl/contrib/opensolaris/lib/pyzfs/common/ioctl.c b/cddl/contrib/opensolaris/lib/pyzfs/common/ioctl.c
index c0de5c4..4571147 100644
--- a/cddl/contrib/opensolaris/lib/pyzfs/common/ioctl.c
+++ b/cddl/contrib/opensolaris/lib/pyzfs/common/ioctl.c
@@ -33,6 +33,7 @@
#include <zone.h>
#include <libintl.h>
#include <libzfs.h>
+#include <libzfs_impl.h>
#include "zfs_prop.h"
static PyObject *ZFSError;
OpenPOWER on IntegriCloud