summaryrefslogtreecommitdiff
path: root/usr/src/lib/libzfs/common/libzfs_dataset.c
diff options
context:
space:
mode:
authorMatthew Ahrens <Matthew.Ahrens@Sun.COM>2009-11-05 15:39:49 -0800
committerMatthew Ahrens <Matthew.Ahrens@Sun.COM>2009-11-05 15:39:49 -0800
commit2d5843db7439a2f07385993dc762c76159967f5a (patch)
treed80770a1afd43b053d7a2ddfa20670a0f47a8155 /usr/src/lib/libzfs/common/libzfs_dataset.c
parent5895e34b428f1f8306218e01067b97c05f75d238 (diff)
downloadillumos-gate-2d5843db7439a2f07385993dc762c76159967f5a.tar.gz
6893929 User/group quotas passed to "zfs create" are not properly set
Diffstat (limited to 'usr/src/lib/libzfs/common/libzfs_dataset.c')
-rw-r--r--usr/src/lib/libzfs/common/libzfs_dataset.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/usr/src/lib/libzfs/common/libzfs_dataset.c b/usr/src/lib/libzfs/common/libzfs_dataset.c
index df5bf7a3a2..13acb5bc68 100644
--- a/usr/src/lib/libzfs/common/libzfs_dataset.c
+++ b/usr/src/lib/libzfs/common/libzfs_dataset.c
@@ -815,9 +815,14 @@ zfs_valid_proplist(libzfs_handle_t *hdl, zfs_type_t type, nvlist_t *nvl,
goto error;
}
+ /*
+ * Encode the prop name as
+ * userquota@<hex-rid>-domain, to make it easy
+ * for the kernel to decode.
+ */
(void) snprintf(newpropname, sizeof (newpropname),
- "%s%s", zfs_userquota_prop_prefixes[uqtype],
- domain);
+ "%s%llx-%s", zfs_userquota_prop_prefixes[uqtype],
+ (longlong_t)rid, domain);
valary[0] = uqtype;
valary[1] = rid;
valary[2] = intval;