diff options
Diffstat (limited to 'cli')
| -rw-r--r-- | cli/src/cli-rpc-ops.c | 16 | 
1 files changed, 6 insertions, 10 deletions
diff --git a/cli/src/cli-rpc-ops.c b/cli/src/cli-rpc-ops.c index bd0d4d8a2c2..dd92a15368f 100644 --- a/cli/src/cli-rpc-ops.c +++ b/cli/src/cli-rpc-ops.c @@ -3287,16 +3287,12 @@ print_quota_list_from_quotad (call_frame_t *frame, dict_t *rsp_dict)          limits.hl = ntoh64 (size_limits->hl);          limits.sl = ntoh64 (size_limits->sl); -        ret = quota_dict_get_meta (rsp_dict, QUOTA_SIZE_KEY, &used_space); -        if (ret == -2 && type == GF_QUOTA_OPTION_TYPE_LIST) { -                ret = 0; -                /* quota_dict_get_meta returns -2 if metadata for inode -                 * quotas is missing. -                 * This can happen when glusterfs is upgraded from 3.6 to 3.7 -                 * and the xattr healing is not completed. -                 * We can contiue as success if we are listing only file usage -                 */ -        } +        if (type == GF_QUOTA_OPTION_TYPE_LIST) +                ret = quota_dict_get_meta (rsp_dict, QUOTA_SIZE_KEY, +                                           &used_space); +        else +                ret = quota_dict_get_inode_meta (rsp_dict, QUOTA_SIZE_KEY, +                                                 &used_space);          if (ret < 0) {                  gf_log ("cli", GF_LOG_WARNING,  | 
