diff options
author | Yaniv Kaul <ykaul@redhat.com> | 2018-09-23 11:04:22 +0300 |
---|---|---|
committer | Amar Tumballi <amarts@redhat.com> | 2018-09-26 04:17:30 +0000 |
commit | 341ba81448e869ae388b4b37556e47f6bf7413a5 (patch) | |
tree | 2867552e09e07d4320fc9cefb96a9533fc719658 /libglusterfs/src/quota-common-utils.h | |
parent | 064b24900e1f5e3ba3087f7c6a0249613ebed61f (diff) |
Quota related files: use dict_{setn|getn|deln|get_int32n|set_int32n|set_strn}
In a previous patch (https://review.gluster.org/20769) we've
added the key length to be passed to dict_* funcs, to remove the need
to strlen() it. This patch moves some code to use it.
Please review carefully.
Compile-tested only!
updates: bz#1193929
Signed-off-by: Yaniv Kaul <ykaul@redhat.com>
Change-Id: If4f425a9827be7c36ccfbb9761006ae824a818c6
Diffstat (limited to 'libglusterfs/src/quota-common-utils.h')
-rw-r--r-- | libglusterfs/src/quota-common-utils.h | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/libglusterfs/src/quota-common-utils.h b/libglusterfs/src/quota-common-utils.h index 7c3ce498427..49f238b31f3 100644 --- a/libglusterfs/src/quota-common-utils.h +++ b/libglusterfs/src/quota-common-utils.h @@ -39,13 +39,15 @@ gf_boolean_t quota_meta_is_null(const quota_meta_t *meta); int32_t -quota_data_to_meta(data_t *data, char *key, quota_meta_t *meta); +quota_data_to_meta(data_t *data, quota_meta_t *meta); int32_t -quota_dict_get_inode_meta(dict_t *dict, char *key, quota_meta_t *meta); +quota_dict_get_inode_meta(dict_t *dict, char *key, const int keylen, + quota_meta_t *meta); int32_t -quota_dict_get_meta(dict_t *dict, char *key, quota_meta_t *meta); +quota_dict_get_meta(dict_t *dict, char *key, const int keylen, + quota_meta_t *meta); int32_t quota_dict_set_meta(dict_t *dict, char *key, const quota_meta_t *meta, |