diff options
author | Christoph Hellwig <hch@infradead.org> | 2010-02-16 03:44:56 -0500 |
---|---|---|
committer | Jan Kara <jack@suse.cz> | 2010-03-04 18:20:25 -0500 |
commit | ac0e773718dc20551e72900d2e7eada96ac91100 (patch) | |
tree | c46ec45c2044b0995ef241be4b800527210414d7 /fs/xfs/linux-2.6 | |
parent | 5582c76f901d240f57329212b59b4d957ea8d6cf (diff) |
quota: drop permission checks from xfs_fs_set_xstate/xfs_fs_set_xquota
We already do these checks in the generic code.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jan Kara <jack@suse.cz>
Diffstat (limited to 'fs/xfs/linux-2.6')
-rw-r--r-- | fs/xfs/linux-2.6/xfs_quotaops.c | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/fs/xfs/linux-2.6/xfs_quotaops.c b/fs/xfs/linux-2.6/xfs_quotaops.c index 07d67c624922..1947514ce1ad 100644 --- a/fs/xfs/linux-2.6/xfs_quotaops.c +++ b/fs/xfs/linux-2.6/xfs_quotaops.c | |||
@@ -68,8 +68,6 @@ xfs_fs_set_xstate( | |||
68 | return -EROFS; | 68 | return -EROFS; |
69 | if (op != Q_XQUOTARM && !XFS_IS_QUOTA_RUNNING(mp)) | 69 | if (op != Q_XQUOTARM && !XFS_IS_QUOTA_RUNNING(mp)) |
70 | return -ENOSYS; | 70 | return -ENOSYS; |
71 | if (!capable(CAP_SYS_ADMIN)) | ||
72 | return -EPERM; | ||
73 | 71 | ||
74 | if (uflags & XFS_QUOTA_UDQ_ACCT) | 72 | if (uflags & XFS_QUOTA_UDQ_ACCT) |
75 | flags |= XFS_UQUOTA_ACCT; | 73 | flags |= XFS_UQUOTA_ACCT; |
@@ -130,8 +128,6 @@ xfs_fs_set_xquota( | |||
130 | return -ENOSYS; | 128 | return -ENOSYS; |
131 | if (!XFS_IS_QUOTA_ON(mp)) | 129 | if (!XFS_IS_QUOTA_ON(mp)) |
132 | return -ESRCH; | 130 | return -ESRCH; |
133 | if (!capable(CAP_SYS_ADMIN)) | ||
134 | return -EPERM; | ||
135 | 131 | ||
136 | return -xfs_qm_scall_setqlim(mp, id, xfs_quota_type(type), fdq); | 132 | return -xfs_qm_scall_setqlim(mp, id, xfs_quota_type(type), fdq); |
137 | } | 133 | } |