summaryrefslogtreecommitdiff
path: root/qgroup.h
diff options
context:
space:
mode:
authorWang Shilong <wangsl-fnst@cn.fujitsu.com>2013-01-20 16:04:15 -0500
committerDavid Sterba <dsterba@suse.cz>2013-01-21 18:28:01 +0100
commit9886166880ad36f586edd8f9fd220cc416b0d594 (patch)
treec592aae4222857429e83de86debaec4d63c8035b /qgroup.h
parentf933e084eafe3f0b441f0ffb99505fc34a66194e (diff)
Btrfs-progs: clean up reduplicate parse_qgroupid() and replace atoi with strtoull
1. parse_qgroupid() is implemented twice, clean up the reduplicate code. 2. atoi() can not detect errors, so use strtoull() instead of it. Signed-off-by: Wang Shilong <wangsl-fnst@cn.fujitsu.com> Signed-off-by: Miao Xie <miaox@cn.fujitsu.com> Signed-off-by: Gene Czarcinski <gene@czarc.net>
Diffstat (limited to 'qgroup.h')
-rw-r--r--qgroup.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/qgroup.h b/qgroup.h
index f7af8c53..ad14c888 100644
--- a/qgroup.h
+++ b/qgroup.h
@@ -20,7 +20,9 @@
#define _BTRFS_QGROUP_H
#include "ioctl.h"
+#include "kerncompat.h"
+u64 parse_qgroupid(char *p);
int qgroup_inherit_size(struct btrfs_qgroup_inherit *p);
int qgroup_inherit_realloc(struct btrfs_qgroup_inherit **inherit,
int incgroups, int inccopies);