diff options
author | Sean Eric Fagan <sef@FreeBSD.org> | 2019-01-11 02:53:46 +0000 |
---|---|---|
committer | Sean Eric Fagan <sef@FreeBSD.org> | 2019-01-11 02:53:46 +0000 |
commit | 82e20c0a7279b8d9bd16f5dfd10482344140a220 (patch) | |
tree | 0952910b745b6dc2ae8fcef650816c0bb7fe0d2b /sys/cddl/contrib/opensolaris/uts | |
parent | 48266154de46c1290cba3574a8f13c5bfc697964 (diff) | |
download | src-82e20c0a7279b8d9bd16f5dfd10482344140a220.tar.gz src-82e20c0a7279b8d9bd16f5dfd10482344140a220.zip |
Change ZFS quotas to return EINVAL when not present (matches man page).
UFS will return EINVAL when quotas are not enabled on a filesystem; ZFS'
equivalent involves not having quotas (there is not way to enable or disable
quotas as such). My initial implementation had it return ENOENT, but
quotactl(2) indicates EINVAL is more appropriate.
MFC after: 2 weeks
Approved by: mav
Reviewed by: markj
Reported by: Emrion <kmachine@free.fr>
Sponsored by: iXsystems Inc
PR: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=234413
Notes
Notes:
svn path=/head/; revision=342928
Diffstat (limited to 'sys/cddl/contrib/opensolaris/uts')
-rw-r--r-- | sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vfsops.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vfsops.c b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vfsops.c index b372e9734aa5..7255a09f5757 100644 --- a/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vfsops.c +++ b/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vfsops.c @@ -144,7 +144,7 @@ zfs_getquota(zfsvfs_t *zfsvfs, uid_t id, int isgroup, struct dqblk64 *dqp) quotaobj = isgroup ? zfsvfs->z_groupquota_obj : zfsvfs->z_userquota_obj; if (quotaobj == 0 || zfsvfs->z_replay) { - error = ENOENT; + error = EINVAL; goto done; } (void)sprintf(buf, "%llx", (longlong_t)id); |