projects
/
platform
/
kernel
/
linux-amlogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
cc975eb
)
Btrfs: disable qgroup id 0
author
Miao Xie
<miaox@cn.fujitsu.com>
Thu, 15 Nov 2012 11:35:41 +0000
(11:35 +0000)
committer
Josef Bacik
<josef@toxicpanda.com>
Mon, 14 Jan 2013 18:52:31 +0000
(13:52 -0500)
Qgroup id 0 is a special number, we should set the id of a qgroup to 0.
Fix it.
Signed-off-by: Miao Xie <miaox@cn.fujitsu.com>
fs/btrfs/ioctl.c
patch
|
blob
|
history
diff --git
a/fs/btrfs/ioctl.c
b/fs/btrfs/ioctl.c
index
7624212
..
dd8e344
100644
(file)
--- a/
fs/btrfs/ioctl.c
+++ b/
fs/btrfs/ioctl.c
@@
-3698,6
+3698,11
@@
static long btrfs_ioctl_qgroup_create(struct file *file, void __user *arg)
goto drop_write;
}
+ if (!sa->qgroupid) {
+ ret = -EINVAL;
+ goto out;
+ }
+
trans = btrfs_join_transaction(root);
if (IS_ERR(trans)) {
ret = PTR_ERR(trans);