From 0ddd69a60e49f1335ed29a8225e31d24c836083a Mon Sep 17 00:00:00 2001 From: Varun Shastry Date: Wed, 12 Mar 2014 15:22:14 +0530 Subject: features/quota: fix the dict leak when quota is off Change-Id: Iafe0c5104e38a1e34de1f2c2a19682178eb60e11 BUG: 1075506 Signed-off-by: Varun Shastry Reviewed-on: http://review.gluster.org/7227 Tested-by: Gluster Build System Reviewed-by: Vijay Bellur --- xlators/features/quota/src/quota.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/xlators/features/quota/src/quota.c b/xlators/features/quota/src/quota.c index bb5dc7aba..4beaae341 100644 --- a/xlators/features/quota/src/quota.c +++ b/xlators/features/quota/src/quota.c @@ -1075,12 +1075,12 @@ quota_lookup (call_frame_t *frame, xlator_t *this, loc_t *loc, priv = this->private; + WIND_IF_QUOTAOFF (priv->is_quota_on, off); + xattr_req = xattr_req ? dict_ref(xattr_req) : dict_new(); if (!xattr_req) goto err; - WIND_IF_QUOTAOFF (priv->is_quota_on, off); - local = quota_local_new (); if (local == NULL) { goto err; -- cgit