[PATCH] Consistently use zfs_ioctl()
Pawel Jakub Dawidek
pjd at FreeBSD.org
Wed Jul 27 05:34:52 UTC 2011
On Tue, Jul 26, 2011 at 10:55:11PM +0200, Martin Matuska wrote:
> I have chatted with delphij@ and he said his problem was in zfs jail /
> unjail.
>
> The problem is in zfs_jail(), cmd passed to ioctl() is initialized as
> int instead of unsigned long.
> Patch suggested for fixing this problem is attached.
Looks good to me.
> Index: cddl/contrib/opensolaris/lib/libzfs/common/libzfs_dataset.c
> ===================================================================
> --- cddl/contrib/opensolaris/lib/libzfs/common/libzfs_dataset.c (revision 224409)
> +++ cddl/contrib/opensolaris/lib/libzfs/common/libzfs_dataset.c (working copy)
> @@ -4289,7 +4289,8 @@
> libzfs_handle_t *hdl = zhp->zfs_hdl;
> zfs_cmd_t zc = { 0 };
> char errbuf[1024];
> - int cmd, ret;
> + unsigned long cmd;
> + int ret;
>
> if (attach) {
> (void) snprintf(errbuf, sizeof (errbuf),
--
Pawel Jakub Dawidek http://www.wheelsystems.com
FreeBSD committer http://www.FreeBSD.org
Am I Evil? Yes, I Am! http://yomoli.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/zfs-devel/attachments/20110727/d09f76a6/attachment.pgp
More information about the zfs-devel
mailing list