summaryrefslogtreecommitdiffstats
path: root/libglusterfs
diff options
context:
space:
mode:
Diffstat (limited to 'libglusterfs')
-rw-r--r--libglusterfs/src/quota-common-utils.c14
-rw-r--r--libglusterfs/src/quota-common-utils.h3
2 files changed, 16 insertions, 1 deletions
diff --git a/libglusterfs/src/quota-common-utils.c b/libglusterfs/src/quota-common-utils.c
index 8c528c8bd3b..0c93303a5ae 100644
--- a/libglusterfs/src/quota-common-utils.c
+++ b/libglusterfs/src/quota-common-utils.c
@@ -57,7 +57,7 @@ out:
}
int32_t
-quota_dict_get_meta (dict_t *dict, char *key, quota_meta_t *meta)
+quota_dict_get_inode_meta (dict_t *dict, char *key, quota_meta_t *meta)
{
int32_t ret = -1;
data_t *data = NULL;
@@ -77,6 +77,18 @@ out:
}
int32_t
+quota_dict_get_meta (dict_t *dict, char *key, quota_meta_t *meta)
+{
+ int32_t ret = -1;
+
+ ret = quota_dict_get_inode_meta (dict, key, meta);
+ if (ret == -2)
+ ret = 0;
+
+ return ret;
+}
+
+int32_t
quota_dict_set_meta (dict_t *dict, char *key, const quota_meta_t *meta,
ia_type_t ia_type)
{
diff --git a/libglusterfs/src/quota-common-utils.h b/libglusterfs/src/quota-common-utils.h
index 2c3632b903c..c930db8e86c 100644
--- a/libglusterfs/src/quota-common-utils.h
+++ b/libglusterfs/src/quota-common-utils.h
@@ -41,6 +41,9 @@ int32_t
quota_data_to_meta (data_t *data, char *key, quota_meta_t *meta);
int32_t
+quota_dict_get_inode_meta (dict_t *dict, char *key, quota_meta_t *meta);
+
+int32_t
quota_dict_get_meta (dict_t *dict, char *key, quota_meta_t *meta);
int32_t